Uint8ListDataExtension extension

Data Extension for Uint8List.

on

Properties

bits String
Returns this bytes as String of bits.
no setter
bits8 String
Returns this bytes as 8 bits String.
no setter
bits16 String
Returns this bytes as 16 bits String.
no setter
bits32 String
Returns this bytes as 32 bits String.
no setter
bits64 String
Returns this bytes as 64 bits String.
no setter

Methods

asByteData() ByteData
Returns a ByteData of this buffer with the respective offset and length.
bitsPadded(int width) String
Returns this bytes as String of bits of length width.
bytesHashCode() int
Returns a hashcode of this bytes.
convertToUint16List([Endian endian = Endian.big]) Uint16List
Converts this instance to an Uint16List.
convertToUint32List([Endian endian = Endian.big]) Uint32List
Converts this instance to an Uint32List.
convertToUint64List([Endian endian = Endian.big]) Uint64List
Converts this instance to an Uint64List.
copy() Uint8List
Returns a copy of this instance.
copyAsUnmodifiable() Uint8List
Returns an unmodifiable copy of this instance.
equals(Uint8List other) bool
Returns true of other elements are equals.
getInt16([int byteOffset = 0]) int
Returns a Int16 at byteOffset of this bytes buffer (reads 2 bytes).
getInt32([int byteOffset = 0]) int
Returns a Int32 at byteOffset of this bytes buffer (reads 4 bytes).
getInt64([int byteOffset = 0]) int
Returns a Int64 at byteOffset of this bytes buffer (reads 8 bytes).
getInt8([int byteOffset = 0]) int
Returns a Int8 at byteOffset of this bytes buffer (reads 1 byte).
getUint16([int byteOffset = 0, Endian endian = Endian.big]) int
Returns a Uint16 at byteOffset of this bytes buffer (reads 2 bytes).
getUint32([int byteOffset = 0, Endian endian = Endian.big]) int
Returns a Uint32 at byteOffset of this bytes buffer (reads 4 bytes).
getUint64([int byteOffset = 0, Endian endian = Endian.big]) int
Returns a Uint64 at byteOffset of this bytes buffer (reads 8 bytes).
getUint8([int byteOffset = 0]) int
Returns a Uint8 at byteOffset of this bytes buffer (reads 1 byte).
group(Uint8List other) Uint8List
Groups this instance with other.
merge(Uint8List other, int merger(int a, int b, int index)) Uint8List
Merges this instance with other using the merger Function for each byte.
readBigInt([int offset = 0]) MapEntry<int, BigInt>
Reads a BigInt at offset. See BigIntExtension.toBytes for encoding description.
readBlock16([int offset = 0]) Uint8List
Reads a bytes block, using a Uint16 prefix (2 bytes of length prefix).
readBlock32([int offset = 0]) Uint8List
Reads a bytes block, using a Uint32 prefix (4 bytes of length prefix).
readBytes([int offset = 0, int? length]) Uint8List
Reads bytes (Uint8List) of length at offset.
readDateTime([int offset = 0]) DateTime
Reads a DateTime at offset. It's encoded as a Uint64 of DateTime.millisecondsSinceEpoch.
readWritables<W extends Writable>(W reader(BytesBuffer input)) List<W>
Reads a list of Writable using the reader function to instantiate the W elements.
reverseBytes() Uint8List
Returns this instance in a reversed order.
setInt16(int n, [int byteOffset = 0]) → void
Sets n as a Int16 at byteOffset.
setInt32(int n, [int byteOffset = 0]) → void
Sets n as a Int32 at byteOffset.
setInt64(int n, [int byteOffset = 0]) → void
Sets n as a Int64 at byteOffset.
setInt8(int n, [int byteOffset = 0]) → void
Sets n as a Int8 at byteOffset.
setUint16(int n, [int byteOffset = 0]) → void
Sets n as a Uint16 at byteOffset.
setUint32(int n, [int byteOffset = 0]) → void
Sets n as a Uint32 at byteOffset.
setUint64(int n, [int byteOffset = 0]) → void
Sets n as a Uint64 at byteOffset.
setUint8(int n, [int byteOffset = 0]) → void
Sets n as a Uint8 at byteOffset.
subView([int offset = 0, int? length]) Uint8List
A sub Uint8List view of region.
subViewTail(int tailLength) Uint8List
A sub Uint8List view of the tail.
tail(int length) Uint8List
The tail of this Uint8List instance.
toBigInt({Endian endian = Endian.big}) BigInt
Converts this bytes to a BigInt (through toHex).
toBytesBuffer({int offset = 0, int? length, int? bufferLength, bool copyBuffer = false}) BytesBuffer
Instantiates a BytesBuffer from this Uint8List instance.
toHex({Endian endian = Endian.big}) String
Converts this bytes to HEX.
toHexBigEndian() String
Converts this bytes to HEX (big-endian).
toHexLittleEndian() String
Converts this bytes to HEX (little-endian).
toListOfInt16() List<int>
Converts this bytes to a List of Int16.
toListOfInt32() List<int>
Converts this bytes to a List of Int32.
toListOfInt64() List<int>
Converts this bytes to a List of Int64.
toListOfInt8() List<int>
Converts this bytes to a List of Int8.
toListOfUint16() List<int>
Converts this bytes to a List of Uint16.
toListOfUint32() List<int>
Converts this bytes to a List of Uint32.
toListOfUint64() List<int>
Converts this bytes to a List of Uint64.
toListOfUint8() List<int>
Converts this bytes to a List of Uint8.
toStringLatin1() String
Decodes this bytes as a LATIN-1 String.
toStringUTF8() String
Decodes this bytes as a UTF-8 String.

Operators

operator &(Uint8List other) Uint8List
Merges this instance with other using the AND logical operator.
operator ^(Uint8List other) Uint8List
Merges this instance with other using the XOR logical operator.
operator |(Uint8List other) Uint8List
Merges this instance with other using the OR logical operator.