structArray<T extends StructDWeb<T>> method

List<T> structArray<T extends StructDWeb<T>>(
  1. int count,
  2. WasmStructPointer<T> pointerFactory(
    1. int ptr
    ), {
  3. bool owned = false,
})

Implementation

List<T> structArray<T extends StructDWeb<T>>(int count, WasmStructPointer<T> Function(int ptr) pointerFactory, {bool owned = false}) {
  final result = pointerFactory(_cur).readArray(count, owned: owned);
  if (result.isNotEmpty) _cur += count * result.first.wasmByteSize;
  return result;
}