Trait serde_v8::V8Sliceable

source ·
pub trait V8Sliceable: Copy + Clone {
    type V8;

    // Required method
    fn new_buf<'s>(
        scope: &mut HandleScope<'s>,
        buf: Local<'_, ArrayBuffer>,
        byte_offset: usize,
        length: usize
    ) -> Option<Local<'s, Self::V8>>;
}
Expand description

A type that may be represented as a V8Slice.

Required Associated Types§

source

type V8

The concrete V8 data view type.

Required Methods§

source

fn new_buf<'s>( scope: &mut HandleScope<'s>, buf: Local<'_, ArrayBuffer>, byte_offset: usize, length: usize ) -> Option<Local<'s, Self::V8>>

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl V8Sliceable for f64

§

type V8 = Float64Array

source§

fn new_buf<'s>( scope: &mut HandleScope<'s>, buf: Local<'_, ArrayBuffer>, byte_offset: usize, length: usize ) -> Option<Local<'s, Self::V8>>

source§

impl V8Sliceable for u8

§

type V8 = Uint8Array

source§

fn new_buf<'s>( scope: &mut HandleScope<'s>, buf: Local<'_, ArrayBuffer>, byte_offset: usize, length: usize ) -> Option<Local<'s, Self::V8>>

source§

impl V8Sliceable for u32

§

type V8 = Uint32Array

source§

fn new_buf<'s>( scope: &mut HandleScope<'s>, buf: Local<'_, ArrayBuffer>, byte_offset: usize, length: usize ) -> Option<Local<'s, Self::V8>>

Implementors§