toBytes method
Uint8List
toBytes({
- required BinaryFormat<
FeatureContent> format, - Endian? endian,
- Map<
String, dynamic> ? options,
The binary representation of this feature object, with format
applied.
An optional endian
specifies endianness for byte sequences written. Some
encoders might ignore this, and some has a default value for it.
Other format or encoder implementation specific options can be set by
options
.
Implementation
Uint8List toBytes({
required BinaryFormat<FeatureContent> format,
Endian? endian,
Map<String, dynamic>? options,
}) {
final encoder = format.encoder(endian: endian, options: options);
writeTo(encoder.writer);
return encoder.toBytes();
}