Array<T extends NativeType>.variableMulti constructor

  1. @Since('3.6')
const Array<T extends NativeType>.variableMulti(
  1. List<int> dimensions
)

Annotation to a variable length Array in Structs.

final class MyStruct extends Struct {
  @Array.variableMulti([2, 2])
  external Array<Array<Array<Uint8>>> threeDimensionalInlineArray;
}

final class MyStruct2 extends Struct {
  @Array.variableMulti([2, 2, 2, 2, 2, 2, 2])
  external Array<Array<Array<Array<Array<Array<Array<Array<Uint8>>>>>>>> eightDimensionalInlineArray;
}

The variable lenght is always the outermost dimension of the array.

Do not invoke in normal code.

Implementation

@Since('3.6')
const factory Array.variableMulti(List<int> dimensions) =
    _ArraySize<T>.variableMulti;