pub struct ArrayBuffer(pub Vec<u8>);
Expand description
Wrapper for converting between Vec<u8>
and JsArrayBuffer
Tuple Fields§
§0: Vec<u8>
Trait Implementations§
Source§impl<'cx> TryFromJs<'cx> for ArrayBuffer
impl<'cx> TryFromJs<'cx> for ArrayBuffer
type Error = TypeExpected<JsBuffer>
Source§fn try_from_js(
cx: &mut Cx<'cx>,
v: Handle<'cx, JsValue>,
) -> NeonResult<Result<Self, Self::Error>>
fn try_from_js( cx: &mut Cx<'cx>, v: Handle<'cx, JsValue>, ) -> NeonResult<Result<Self, Self::Error>>
Extract this Rust type from a JavaScript value
Source§impl<'cx> TryIntoJs<'cx> for ArrayBuffer
impl<'cx> TryIntoJs<'cx> for ArrayBuffer
Source§type Value = JsArrayBuffer
type Value = JsArrayBuffer
The type of JavaScript value that will be created
Auto Trait Implementations§
impl Freeze for ArrayBuffer
impl RefUnwindSafe for ArrayBuffer
impl Send for ArrayBuffer
impl Sync for ArrayBuffer
impl Unpin for ArrayBuffer
impl UnwindSafe for ArrayBuffer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more