Int16Array
t
type t = Core__TypedArray.t<int>The Int16Array typed array represents an array of twos-complement 16-bit signed integers in platform byte order. See Int16Array on MDN
fromArray
let fromArray: array<int> => tfromArray creates a Int16Array from an array of values. See TypedArray constructor on MDN
fromBuffer
let fromBuffer: Core__ArrayBuffer.t => tfromBuffer creates a Int16Array from an ArrayBuffer.t. See TypedArray constructor on MDN
Note: This is a potentially unsafe operation. Ensure the buffer is large enough and only accessed within its bounds.
fromBufferToEnd
let fromBufferToEnd: (Core__ArrayBuffer.t, ~byteOffset: int) => tfromBufferToEnd creates a Int16Array from an ArrayBuffer.t, starting at a particular offset and continuing through to the end. See TypedArray constructor on MDN
Note: This is a potentially unsafe operation. Ensure the buffer is large enough and only accessed within its bounds.
fromBufferWithRange
let fromBufferWithRange: (Core__ArrayBuffer.t, ~byteOffset: int, ~length: int) => tfromBufferWithRange creates a Int16Array from an ArrayBuffer.t, starting at a particular offset and consuming length bytes. See TypedArray constructor on MDN
Note: This is a potentially unsafe operation. Ensure the buffer is large enough and only accessed within its bounds.
fromLength
let fromLength: int => tfromLength creates a zero-initialized Int16Array to hold the specified count of numbers; this is not a byte length. See TypedArray constructor on MDN
Note: This is a potentially unsafe operation. Ensure the buffer is large enough and only accessed within its bounds.
fromArrayLikeOrIterable
let fromArrayLikeOrIterable: 'a => tfromArrayLikeOrIterable creates a Int16Array from an array-like or iterable object. See TypedArray.from on MDN
fromArrayLikeOrIterableWithMap
let fromArrayLikeOrIterableWithMap: ('a, ('b, int) => int) => tfromArrayLikeOrIterableWithMap creates a Int16Array from an array-like or iterable object and applies the mapping function to each item. The mapping function expects (value, index). See TypedArray.from on MDN