vecU8 static method
vector bytes
Implementation
static CustomLayout vecU8({
String? property,
IntegerLayout? lengthSizeLayout,
}) {
final resolvedLength = _lengthLayoutFor(lengthSizeLayout);
final length = padding(resolvedLength, property: "length");
final layout = struct([
length,
blob(offset(length, -length.span), property: 'data'),
]);
return CustomLayout(
layout: layout,
encoder: (data) => {"data": data},
decoder: (data) => data["data"],
property: property,
);
}