getUint32Le
getUint32Le(
data,offset,byteLength?):number
Defined in: packages/core/src/buffer/codec/get-uint32-le.ts:17
Reads a little-endian unsigned integer from data at offset.
Unlike DataView.getUint32, this reads straight from the array and therefore
needs no view object per call. The caller is responsible for ensuring that
byteLength bytes are available at offset.
Parameters
Section titled “Parameters”Uint8Array
The bytes to read from.
offset
Section titled “offset”number
The index of the first byte to read.
byteLength?
Section titled “byteLength?”number = 4
How many bytes to read, in the 0..4 range. Defaults to 4 (a full word); fewer bytes read a narrower little-endian integer formed from just those leading bytes, which for little-endian is equivalent to zero-padding the missing high bytes — for a binary format’s variable-width or partial trailing fields.
Returns
Section titled “Returns”number
The value as an unsigned 32-bit integer.