Struct mv_async_vm::async_vm::AsyncSession
source · [−]pub struct AsyncSession<'r, 'l, S> { /* private fields */ }Expand description
Represents an Async Move execution session.
Implementations
sourceimpl<'r, 'l, S: MoveResolver> AsyncSession<'r, 'l, S>
impl<'r, 'l, S: MoveResolver> AsyncSession<'r, 'l, S>
sourcepub fn get_move_session(&mut self) -> &mut Session<'r, 'l, S>
pub fn get_move_session(&mut self) -> &mut Session<'r, 'l, S>
Get the underlying Move VM session.
sourcepub fn new_actor(
self,
module_id: &ModuleId,
actor_addr: AccountAddress,
gas_status: &mut GasStatus<'_>
) -> AsyncResult
pub fn new_actor(
self,
module_id: &ModuleId,
actor_addr: AccountAddress,
gas_status: &mut GasStatus<'_>
) -> AsyncResult
Creates a new actor, identified by the module_id, at the given account address. This calls the initializer function of the actor, and returns on success a changeset which needs to be committed to persist the new actors state.
sourcepub fn handle_message(
self,
actor_addr: AccountAddress,
message_hash: u64,
args: Vec<Vec<u8>>,
gas_status: &mut GasStatus<'_>
) -> AsyncResult
pub fn handle_message(
self,
actor_addr: AccountAddress,
message_hash: u64,
args: Vec<Vec<u8>>,
gas_status: &mut GasStatus<'_>
) -> AsyncResult
Handles a message at actor with the given message_hash. This will call the
according function as determined by the AsyncResolver, passing a reference to
the actors state.
Auto Trait Implementations
impl<'r, 'l, S> !RefUnwindSafe for AsyncSession<'r, 'l, S>
impl<'r, 'l, S> !Send for AsyncSession<'r, 'l, S>
impl<'r, 'l, S> !Sync for AsyncSession<'r, 'l, S>
impl<'r, 'l, S> Unpin for AsyncSession<'r, 'l, S>
impl<'r, 'l, S> !UnwindSafe for AsyncSession<'r, 'l, S>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more