Trait js::typedarray::TypedArrayElementCreator
[−]
[src]
pub trait TypedArrayElementCreator: TypedArrayElement { unsafe fn create_new(cx: *mut JSContext, length: u32) -> *mut JSObject; unsafe fn get_data(obj: *mut JSObject) -> *mut Self::Element; }
Internal trait for creating new typed arrays.
Required Methods
unsafe fn create_new(cx: *mut JSContext, length: u32) -> *mut JSObject
Create a new typed array.
unsafe fn get_data(obj: *mut JSObject) -> *mut Self::Element
Get the data.
Implementors
impl TypedArrayElementCreator for Uint8
impl TypedArrayElementCreator for Uint16
impl TypedArrayElementCreator for Uint32
impl TypedArrayElementCreator for Int8
impl TypedArrayElementCreator for Int16
impl TypedArrayElementCreator for Int32
impl TypedArrayElementCreator for Float32
impl TypedArrayElementCreator for Float64
impl TypedArrayElementCreator for ClampedU8
impl TypedArrayElementCreator for ArrayBufferU8