Skip to main content

Closure

Type Alias Closure 

Source
pub type Closure<T> = ScopedClosure<'static, T>;
Expand description

Owned closure handle. This follows upstream wasm-bindgen’s alias direction.

Aliased Type§

pub struct Closure<T> { /* private fields */ }

Trait Implementations§

Source§

impl<F: ?Sized> BatchableResult for Closure<F>

Source§

fn try_placeholder(batch: &mut Runtime) -> Option<Self>

Returns Some(placeholder) for opaque types that can be batched, None for types that require flushing to get the actual value. Read more
Source§

impl<F: ?Sized> BinaryDecode for Closure<F>

Source§

fn decode(decoder: &mut DecodedData<'_>) -> Result<Self, DecodeError>

Source§

impl<F: ?Sized> BinaryEncode for Closure<F>

Source§

fn encode(self, encoder: &mut EncodedData)