Skip to main content

Interface: IType<ValueType, BitSize>

Type Parameters

Type Parameter
ValueType
BitSize extends number | null

Properties

BIT_SIZE

readonly BIT_SIZE: BitSize

The size of the value in bits, or null if the size is variable.

Defined in

types/base/IType.ts:24

Methods

deserialize()

deserialize(buffer: UnalignedUint16Array, pointer: Pointer): ValueType

Deserialize a value from a buffer.

Parameters

ParameterTypeDescription
bufferUnalignedUint16ArrayThe buffer to read from
pointerPointerThe pointer indicating the current position in the buffer

Returns

ValueType

Defined in

types/base/IType.ts:19


serialize()

serialize(buffer: UnalignedUint16Array, value: Readonly<ValueType>): void

Serialize a value to a buffer.

Parameters

ParameterTypeDescription
bufferUnalignedUint16ArrayThe buffer to write to
valueReadonly<ValueType>The value to write

Returns

void

Defined in

types/base/IType.ts:11