GuestBufferView
A wrapper around a TypedArray
(e.g. Uint8Array
), Buffer
, or any view-like value which exposes an inner ArrayBuffer
, offset, and length.
This wrapper can be used to easily interact with typed arrays and their inner array buffers. Use tryFrom to attempt wrapping a value without throwing an exception for invalid cases.
Functions
Link copied to clipboard
Returns the offset in the backing array buffer at which this view starts.
Link copied to clipboard
Returns the array buffer backing this view, as a GuestBytes wrapper. The returned value is validated and is guaranteed to contain buffer elements.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard