Skip to content

jDataView constructor

Zade Viggers edited this page May 23, 2024 · 2 revisions

Note

This page has been updated for jDataView 3

Explanation

jDataVIew introduces an extra littleEndian argument to the constructor, which is used as the default mode of all the I/O operations if their littleEndian value is not passed explicitly.

There's also the jDataView.from(...data) static method, if your data is little endian.

Reference

type Bufferish = string | number | ArrayBuffer | ArrayLike<number>;

new jDataView(
    buffer: Bufferish,
    offset?: number,
    length?: number,
    littleEndian = false
)

jDataView.from(...data: Bufferish[]): jDataView;
Clone this wiki locally