pub trait OptionIntoWasmAbi: IntoWasmAbi {
    fn none() -> Self::Abi;
}
Expand description

Indicates that this type can be passed to JS as Option<Self>.

This trait is used when implementing IntoWasmAbi for Option<T>.

Required Methods§

source

fn none() -> Self::Abi

Returns an ABI instance indicating “none”, which JS will interpret as the None branch of this option.

It should be guaranteed that the IntoWasmAbi can never produce the ABI value returned here.

Implementations on Foreign Types§

source§

impl OptionIntoWasmAbi for i8

source§

impl OptionIntoWasmAbi for u8

source§

impl OptionIntoWasmAbi for i16

source§

impl OptionIntoWasmAbi for u16

source§

impl OptionIntoWasmAbi for bool

source§

impl OptionIntoWasmAbi for char

source§

impl OptionIntoWasmAbi for Box<[u8]>

source§

impl<'a> OptionIntoWasmAbi for &'a [u8]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [u8]

source§

impl OptionIntoWasmAbi for Box<[i8]>

source§

impl<'a> OptionIntoWasmAbi for &'a [i8]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [i8]

source§

impl OptionIntoWasmAbi for Box<[u16]>

source§

impl<'a> OptionIntoWasmAbi for &'a [u16]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [u16]

source§

impl OptionIntoWasmAbi for Box<[i16]>

source§

impl<'a> OptionIntoWasmAbi for &'a [i16]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [i16]

source§

impl OptionIntoWasmAbi for Box<[u32]>

source§

impl<'a> OptionIntoWasmAbi for &'a [u32]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [u32]

source§

impl OptionIntoWasmAbi for Box<[i32]>

source§

impl<'a> OptionIntoWasmAbi for &'a [i32]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [i32]

source§

impl OptionIntoWasmAbi for Box<[u64]>

source§

impl<'a> OptionIntoWasmAbi for &'a [u64]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [u64]

source§

impl OptionIntoWasmAbi for Box<[i64]>

source§

impl<'a> OptionIntoWasmAbi for &'a [i64]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [i64]

source§

impl OptionIntoWasmAbi for Box<[usize]>

source§

impl<'a> OptionIntoWasmAbi for &'a [usize]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [usize]

source§

impl OptionIntoWasmAbi for Box<[isize]>

source§

impl<'a> OptionIntoWasmAbi for &'a [isize]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [isize]

source§

impl OptionIntoWasmAbi for Box<[f32]>

source§

impl<'a> OptionIntoWasmAbi for &'a [f32]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [f32]

source§

impl OptionIntoWasmAbi for Box<[f64]>

source§

impl<'a> OptionIntoWasmAbi for &'a [f64]

source§

impl<'a> OptionIntoWasmAbi for &'a mut [f64]

source§

impl<T> OptionIntoWasmAbi for Vec<T>where
    Box<[T]>: IntoWasmAbi<Abi = WasmSlice>,

source§

impl OptionIntoWasmAbi for String

source§

fn none() -> Self::Abi

source§

impl<'a> OptionIntoWasmAbi for &'a str

source§

fn none() -> Self::Abi

source§

impl OptionIntoWasmAbi for Box<[JsValue]>

source§

impl<T> OptionIntoWasmAbi for Box<[T]>where
    T: JsObject,

Implementors§

source§

impl<'a, T> OptionIntoWasmAbi for &'a Closure<T>where
    T: WasmClosure + ?Sized,