DataSerializerPlatform class abstract

data_serializer platform dependent functions. The implementation resolve special cases for each platform.

Constructors

DataSerializerPlatform()
Returns instance singleton.
factory
DataSerializerPlatform.base()

Properties

hashCode int
The hash code for this object.
no setterinherited
maxSafeInt int
The maximum safe int int the current platform.
no setter
maxSafeIntAsBigInt BigInt
The maximum safe int int the current platform as BigInt.
no setter
maxSafeIntBytes Uint8List
The maximum safe int int the current platform as Uint8List.
no setter
minSafeInt int
The minimum safe int int the current platform.
no setter
minSafeIntAsBigInt BigInt
The minimum safe int int the current platform as BigInt.
no setter
minSafeIntBytes Uint8List
The minimum safe int int the current platform as Uint8List.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
safeIntBits int
The amount of bits of a safe integer.
no setter
supportsFullBitsShift bool
Returns true if the platform fully supports bits shift.
no setter
supportsFullInt64 bool
Returns true if the platform fully supports 64 bits integers.
no setter

Methods

checkSafeInteger(int n) → void
Checks if n is a safe int. Throws StateError if is not a safe int.
checkSafeIntegerByBigInt(BigInt n) → void
Checks if n is a safe int. Throws StateError if is not a safe int.
getDataTypeHandlerInt64(IntCodec data, [int offset = 0, Endian endian = Endian.big]) int
Gets a Int64 from data at offset in endian order.
getDataTypeHandlerUint64(IntCodec data, [int offset = 0, Endian endian = Endian.big]) int
Gets a Uint64 from data at offset in endian order.
getInt64(ByteData data, [int offset = 0, Endian endian = Endian.big]) int
Gets a Int64 from data at offset in endian order.
getUint64(ByteData data, [int offset = 0, Endian endian = Endian.big]) int
Gets a Uint64 from data at offset in endian order.
isSafeInteger(int n) bool
Returns true if n is a safe int.
isSafeIntegerByBigInt(BigInt n) bool
Returns true if n is a safe int.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
readInt64(Uint8List out, [int offset = 0, Endian endian = Endian.big]) int
Reads a Int64 from out at offset in endian order.
readUint64(Uint8List out, [int offset = 0, Endian endian = Endian.big]) int
Reads a Uint64 from out at offset in endian order.
setDataTypeHandlerInt64(IntCodec data, int n, [int offset = 0, Endian endian = Endian.big]) → void
Sets data bytes from offset with n as Int64 in endian order.
setDataTypeHandlerUint64(IntCodec data, int n, [int offset = 0, Endian endian = Endian.big]) → void
Sets data bytes from offset with n as Uint64 in endian order.
setInt64(ByteData data, int n, [int offset = 0, Endian endian = Endian.big]) → void
Sets data bytes from offset with n as Int64 in endian order.
setUint64(ByteData data, int n, [int offset = 0, Endian endian = Endian.big]) → void
Sets data bytes from offset with n as Uint64 in endian order.
shiftLeftInt(int n, int shift) int
Performs a left bit shift (<<).
shiftRightInt(int n, int shift) int
Performs a right bit shift (>>).
toString() String
A string representation of this object.
inherited
writeInt64(Uint8List out, int n, [int offset = 0, Endian endian = Endian.big]) → void
Writes n as Int64 to out at offset in endian order.
writeUint64(Uint8List out, int n, [int offset = 0, Endian endian = Endian.big]) → void
Writes n as Uint64 to out at offset in endian order.

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

instance DataSerializerPlatform
Singleton instance of current DataSerializerPlatform implementation.
final