NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

12.1 Array types

An array type is written as a non-array-type followed by one or more rank-specifiers:

array-type:
non-array-type rank-specifiers
non-array-type:
type
rank-specifiers:
rank-specifier
rank-specifiers rank-specifier
rank-specifier:
[ dim-separatorsopt ]
dim-separators:
,
dim-separators
,

A non-array-type is any type that is not itself an array-type.

The rank of an array type is given by the leftmost rank-specifier in the array-type: A rank-specifier indicates that the array is an array with a rank of one plus the number of "," tokens in the rank-specifier.

The element type of an array type is the type that results from deleting the leftmost rank-specifier:

In effect, the rank-specifiers are read from left to right before the final non-array element type. For example, the type int[][,,][,] is a single-dimensional array of three-dimensional arrays of two-dimensional arrays of int.

Arrays with a rank of one are called single-dimensional arrays. Arrays with a rank greater than one are called multi-dimensional arrays, and are also referred to as two-dimensional arrays, three-dimensional arrays, and so on.

At run-time, a value of an array type can be null or a reference to an instance of that array type.