Struct soroban_wasmi::Store
source · [−]pub struct Store<T> { /* private fields */ }
Expand description
The store that owns all data associated to Wasm modules.
Implementations
sourceimpl<T> Store<T>
impl<T> Store<T>
sourcepub fn into_state(self) -> T
pub fn into_state(self) -> T
Consumes self
and returns its user provided state.
sourcepub fn get_step_meter(&self) -> Rc<dyn StepMeter>
pub fn get_step_meter(&self) -> Rc<dyn StepMeter>
Returns the current StepMeter
.
sourcepub fn set_step_meter(&mut self, step_meter: Rc<dyn StepMeter>)
pub fn set_step_meter(&mut self, step_meter: Rc<dyn StepMeter>)
Installs a new StepMeter
.
Trait Implementations
sourceimpl<T> AsContext for Store<T>
impl<T> AsContext for Store<T>
sourcefn as_context(&self) -> StoreContext<'_, Self::UserState>
fn as_context(&self) -> StoreContext<'_, Self::UserState>
Returns the store context that this type provides access to.
sourceimpl<T> AsContextMut for Store<T>
impl<T> AsContextMut for Store<T>
sourcefn as_context_mut(&mut self) -> StoreContextMut<'_, Self::UserState>
fn as_context_mut(&mut self) -> StoreContextMut<'_, Self::UserState>
Returns the store context that this type provides access to.
Auto Trait Implementations
impl<T> !RefUnwindSafe for Store<T>
impl<T> !Send for Store<T>
impl<T> !Sync for Store<T>
impl<T> Unpin for Store<T>where
T: Unpin,
impl<T> !UnwindSafe for Store<T>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
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
impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read morefn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more