pub struct ScenarioTxEnvData {
pub interpreter_context: InterpreterContext,
pub tx_hash: Option<H256>,
}
Expand description
The actual data required to run a scenario locally. This is the minimal environment needed to run txs.
Fields§
§interpreter_context: InterpreterContext
§tx_hash: Option<H256>
Implementations§
Source§impl ScenarioTxEnvData
impl ScenarioTxEnvData
pub fn interpreter_context(&self) -> InterpreterContext
Trait Implementations§
Source§impl Clone for ScenarioTxEnvData
impl Clone for ScenarioTxEnvData
Source§fn clone(&self) -> ScenarioTxEnvData
fn clone(&self) -> ScenarioTxEnvData
Returns a copy 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 Debug for ScenarioTxEnvData
impl Debug for ScenarioTxEnvData
Source§impl Default for ScenarioTxEnvData
impl Default for ScenarioTxEnvData
Source§fn default() -> ScenarioTxEnvData
fn default() -> ScenarioTxEnvData
Returns the “default value” for a type. Read more
Source§impl ScenarioTxEnv for ScenarioTxEnvData
impl ScenarioTxEnv for ScenarioTxEnvData
fn env_data(&self) -> &ScenarioTxEnvData
Source§impl TxEnv for ScenarioTxEnvData
impl TxEnv for ScenarioTxEnvData
type Api = VMHooksApi<StaticApiBackend>
Source§type RHExpect = TxExpect
type RHExpect = TxExpect
Type built by result handlers that translates into the “expect” section in scenarios.
fn resolve_sender_address( &self, ) -> ManagedAddress<<ScenarioTxEnvData as TxEnv>::Api>
fn default_gas_annotation( &self, ) -> ManagedBuffer<<ScenarioTxEnvData as TxEnv>::Api>
fn default_gas_value(&self) -> u64
Source§impl TxEnvWithTxHash for ScenarioTxEnvData
impl TxEnvWithTxHash for ScenarioTxEnvData
fn set_tx_hash(&mut self, tx_hash: H256)
Source§fn take_tx_hash(&mut self) -> Option<H256>
fn take_tx_hash(&mut self) -> Option<H256>
Retrieves current tx hash, while resetting it in self.
Auto Trait Implementations§
impl Freeze for ScenarioTxEnvData
impl RefUnwindSafe for ScenarioTxEnvData
impl Send for ScenarioTxEnvData
impl Sync for ScenarioTxEnvData
impl Unpin for ScenarioTxEnvData
impl UnwindSafe for ScenarioTxEnvData
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> InterpretableFrom<&T> for Twhere
T: Clone,
impl<T> InterpretableFrom<&T> for Twhere
T: Clone,
fn interpret_from(from: &T, _context: &InterpreterContext) -> T
Source§impl<T> InterpretableFrom<T> for T
impl<T> InterpretableFrom<T> for T
fn interpret_from(from: T, _context: &InterpreterContext) -> T
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