ArrayShapeEncoder.Shape 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
編碼陣列形狀。
public:
void Shape(int rank, System::Collections::Immutable::ImmutableArray<int> sizes, System::Collections::Immutable::ImmutableArray<int> lowerBounds);
public void Shape(int rank, System.Collections.Immutable.ImmutableArray<int> sizes, System.Collections.Immutable.ImmutableArray<int> lowerBounds);
member this.Shape : int * System.Collections.Immutable.ImmutableArray<int> * System.Collections.Immutable.ImmutableArray<int> -> unit
Public Sub Shape (rank As Integer, sizes As ImmutableArray(Of Integer), lowerBounds As ImmutableArray(Of Integer))
參數
- rank
- Int32
陣列中的維度數(應為 1 或更多)。
- sizes
- ImmutableArray<Int32>
尺寸。 陣列可以比 rank 短,但不能比 S 長。
- lowerBounds
- ImmutableArray<Int32>
維度下界,或 default(ImmutableArray<T>) 將所有 rank 下界設為 0。
陣列可以比 rank 短,但不能比 S 長。
例外狀況
rank 超出範圍 [1, 0xffff]、小於 sizes.Length或 小於 lowerBounds.Length。
sizes 是 null。