[][src]Trait wasm_bindgen::convert::FromWasmAbi

pub trait FromWasmAbi: WasmDescribe {
    type Abi: WasmAbi;
    unsafe fn from_abi(js: Self::Abi, extra: &mut dyn Stack) -> Self;
}

A trait for anything that can be recovered by-value from the wasm ABI boundary, eg a Rust u8 can be recovered from the wasm ABI u32 type.

This is the by-value variant of the opposite operation as IntoWasmAbi.

Associated Types

The wasm ABI type that this converts from when coming back out from the ABI boundary.

Required Methods

Recover a Self from Self::Abi.

Safety

This is only safe to call when -- and implementations may assume that -- the supplied Self::Abi was previously generated by a call to <Self as IntoWasmAbi>::into_abi() or the moral equivalent in JS.

Implementations on Foreign Types

impl FromWasmAbi for i32
[src]

impl FromWasmAbi for Option<i32>
[src]

impl FromWasmAbi for isize
[src]

impl FromWasmAbi for Option<isize>
[src]

impl FromWasmAbi for u32
[src]

impl FromWasmAbi for Option<u32>
[src]

impl FromWasmAbi for usize
[src]

impl FromWasmAbi for Option<usize>
[src]

impl FromWasmAbi for f32
[src]

impl FromWasmAbi for Option<f32>
[src]

impl FromWasmAbi for f64
[src]

impl FromWasmAbi for Option<f64>
[src]

impl FromWasmAbi for i8
[src]

impl FromWasmAbi for u8
[src]

impl FromWasmAbi for i16
[src]

impl FromWasmAbi for u16
[src]

impl FromWasmAbi for i64
[src]

impl FromWasmAbi for Option<i64>
[src]

impl FromWasmAbi for u64
[src]

impl FromWasmAbi for Option<u64>
[src]

impl FromWasmAbi for bool
[src]

impl FromWasmAbi for char
[src]

impl FromWasmAbi for Option<char>
[src]

impl<T> FromWasmAbi for *const T
[src]

impl<T> FromWasmAbi for *mut T
[src]

impl<T: OptionFromWasmAbi> FromWasmAbi for Option<T>
[src]

impl FromWasmAbi for Box<[u8]>
[src]

impl FromWasmAbi for Box<[i8]>
[src]

impl FromWasmAbi for Box<[u16]>
[src]

impl FromWasmAbi for Box<[i16]>
[src]

impl FromWasmAbi for Box<[u32]>
[src]

impl FromWasmAbi for Box<[i32]>
[src]

impl FromWasmAbi for Box<[u64]>
[src]

impl FromWasmAbi for Box<[i64]>
[src]

impl FromWasmAbi for Box<[f32]>
[src]

impl FromWasmAbi for Box<[f64]>
[src]

impl<T> FromWasmAbi for Vec<T> where
    Box<[T]>: FromWasmAbi<Abi = WasmSlice>, 
[src]

impl FromWasmAbi for String
[src]

impl FromWasmAbi for Box<[JsValue]>
[src]

Implementors

impl FromWasmAbi for JsValue
[src]

impl<T: FromWasmAbi> FromWasmAbi for Clamped<T>
[src]