pub struct WasmExecutionSession { /* private fields */ }Implementations§
Source§impl WasmExecutionSession
impl WasmExecutionSession
pub fn new(plan: InvocationPlan) -> Self
pub fn with_executor( plan: InvocationPlan, executor: Arc<dyn HostServiceExecutor>, ) -> Self
pub fn plan(&self) -> &InvocationPlan
pub fn usage(&self) -> &ExecutionUsage
pub fn host_calls(&self) -> &[HostCall]
pub fn host_service_executions(&self) -> &[HostServiceExecution]
pub fn grant_slots(&self) -> Vec<HostCapabilityGrant>
pub fn execute_host_call( &mut self, call: HostCall, ) -> Result<HostServiceExecution, WasmModelError>
pub fn record_host_call(&mut self, call: HostCall) -> Result<(), WasmModelError>
pub fn reserve_concurrency(&mut self, units: u16) -> Result<(), WasmModelError>
pub fn release_concurrency(&mut self, units: u16)
pub fn finish( self, runtime: Duration, outcome: InvocationOutcome, typed_output: Option<TypedExecutionOutput>, ) -> Result<ExecutionReceipt, WasmModelError>
Trait Implementations§
Source§impl Clone for WasmExecutionSession
impl Clone for WasmExecutionSession
Source§fn clone(&self) -> WasmExecutionSession
fn clone(&self) -> WasmExecutionSession
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for WasmExecutionSession
impl !RefUnwindSafe for WasmExecutionSession
impl Send for WasmExecutionSession
impl Sync for WasmExecutionSession
impl Unpin for WasmExecutionSession
impl UnsafeUnpin for WasmExecutionSession
impl !UnwindSafe for WasmExecutionSession
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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