pub struct MemoryStackState<'backend, B> { /* private fields */ }Implementations§
Source§impl<'backend, B: Backend> MemoryStackState<'backend, B>
impl<'backend, B: Backend> MemoryStackState<'backend, B>
pub fn new(metadata: StackSubstateMetadata, backend: &'backend B) -> Self
Sourcepub fn account_mut(&mut self, address: H160) -> &mut MemoryStackAccount
pub fn account_mut(&mut self, address: H160) -> &mut MemoryStackAccount
Returns a mutable reference to an account given its address
pub fn deconstruct( self, ) -> (impl IntoIterator<Item = Apply<impl IntoIterator<Item = (H256, H256)>>>, impl IntoIterator<Item = Log>)
pub fn withdraw(&mut self, address: H160, value: U256) -> Result<(), ExitError>
pub fn deposit(&mut self, address: H160, value: U256)
Trait Implementations§
Source§impl<'backend, B: Backend> Backend for MemoryStackState<'backend, B>
impl<'backend, B: Backend> Backend for MemoryStackState<'backend, B>
Source§fn block_hash(&self, number: U256) -> H256
fn block_hash(&self, number: U256) -> H256
Environmental block hash.
Source§fn block_number(&self) -> U256
fn block_number(&self) -> U256
Environmental block number.
Source§fn block_coinbase(&self) -> H160
fn block_coinbase(&self) -> H160
Environmental coinbase.
Source§fn block_timestamp(&self) -> U256
fn block_timestamp(&self) -> U256
Environmental block timestamp.
Source§fn block_difficulty(&self) -> U256
fn block_difficulty(&self) -> U256
Environmental block difficulty.
Source§fn block_gas_limit(&self) -> U256
fn block_gas_limit(&self) -> U256
Environmental block gas limit.
Source§fn block_base_fee_per_gas(&self) -> U256
fn block_base_fee_per_gas(&self) -> U256
Environmental block base fee.
Source§impl<'backend, B: Clone> Clone for MemoryStackState<'backend, B>
impl<'backend, B: Clone> Clone for MemoryStackState<'backend, B>
Source§fn clone(&self) -> MemoryStackState<'backend, B>
fn clone(&self) -> MemoryStackState<'backend, B>
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 moreSource§impl<'backend, B: Debug> Debug for MemoryStackState<'backend, B>
impl<'backend, B: Debug> Debug for MemoryStackState<'backend, B>
Source§impl<'backend, B: Backend> StackState for MemoryStackState<'backend, B>
impl<'backend, B: Backend> StackState for MemoryStackState<'backend, B>
fn metadata(&self) -> &StackSubstateMetadata
fn metadata_mut(&mut self) -> &mut StackSubstateMetadata
fn enter(&mut self, is_static: bool)
fn exit_commit(&mut self) -> Result<(), ExitError>
fn exit_revert(&mut self) -> Result<(), ExitError>
fn exit_discard(&mut self) -> Result<(), ExitError>
fn is_empty(&self, address: H160) -> bool
fn deleted(&self, address: H160) -> bool
fn is_cold(&self, address: H160) -> bool
fn is_storage_cold(&self, address: H160, key: H256) -> bool
fn inc_nonce(&mut self, address: H160)
fn set_storage(&mut self, address: H160, key: H256, value: H256)
fn reset_storage(&mut self, address: H160)
fn log(&mut self, address: H160, topics: Vec<H256>, data: Vec<u8>)
fn set_deleted(&mut self, address: H160)
fn set_code(&mut self, address: H160, code: Vec<u8>)
fn transfer(&mut self, transfer: Transfer) -> Result<(), ExitError>
fn reset_balance(&mut self, address: H160)
fn touch(&mut self, address: H160)
Auto Trait Implementations§
impl<'backend, B> Freeze for MemoryStackState<'backend, B>
impl<'backend, B> RefUnwindSafe for MemoryStackState<'backend, B>where
B: RefUnwindSafe,
impl<'backend, B> Send for MemoryStackState<'backend, B>where
B: Sync,
impl<'backend, B> Sync for MemoryStackState<'backend, B>where
B: Sync,
impl<'backend, B> Unpin for MemoryStackState<'backend, B>
impl<'backend, B> UnwindSafe for MemoryStackState<'backend, B>where
B: RefUnwindSafe,
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