pub struct WasmStatefulHandlerV2 { /* private fields */ }Expand description
Sandboxed ABI v2 handler. The linker provides no WASI interfaces, so the guest has no filesystem, network, environment, process, stdio, clock or random imports.
Implementations§
Source§impl WasmStatefulHandlerV2
impl WasmStatefulHandlerV2
Sourcepub fn new(
component_bytes: &[u8],
expected_metadata: StatefulHandlerMetadataV2,
model_json: &Value,
) -> Result<Self, StatefulHandlerErrorV2>
pub fn new( component_bytes: &[u8], expected_metadata: StatefulHandlerMetadataV2, model_json: &Value, ) -> Result<Self, StatefulHandlerErrorV2>
Compile and configure a component whose bytes were already authenticated
by the caller. Guest metadata must exactly match expected_metadata.
Trait Implementations§
Source§impl Debug for WasmStatefulHandlerV2
impl Debug for WasmStatefulHandlerV2
Source§impl StatefulHandlerV2 for WasmStatefulHandlerV2
impl StatefulHandlerV2 for WasmStatefulHandlerV2
fn metadata(&self) -> &StatefulHandlerMetadataV2
fn handle( &self, event_json: &[u8], current_state: &[u8], deterministic_seed: Option<u64>, ) -> Result<StatefulHandlerResultV2, StatefulHandlerErrorV2>
Auto Trait Implementations§
impl !Freeze for WasmStatefulHandlerV2
impl !RefUnwindSafe for WasmStatefulHandlerV2
impl !UnwindSafe for WasmStatefulHandlerV2
impl Send for WasmStatefulHandlerV2
impl Sync for WasmStatefulHandlerV2
impl Unpin for WasmStatefulHandlerV2
impl UnsafeUnpin for WasmStatefulHandlerV2
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