Struct fuel_vm::state::StateTransitionRef
source · [−]pub struct StateTransitionRef<'a> { /* private fields */ }
Expand description
Zero-copy Representation of the result of a transaction execution bound to the lifetime of the VM.
Implementations
sourceimpl<'a> StateTransitionRef<'a>
impl<'a> StateTransitionRef<'a>
sourcepub const fn new(
state: ProgramState,
tx: &'a Transaction,
receipts: &'a [Receipt]
) -> Self
pub const fn new(
state: ProgramState,
tx: &'a Transaction,
receipts: &'a [Receipt]
) -> Self
Create a new by reference state transition representation.
sourcepub const fn state(&self) -> &ProgramState
pub const fn state(&self) -> &ProgramState
Program state representation.
sourcepub const fn tx(&self) -> &Transaction
pub const fn tx(&self) -> &Transaction
Resulting mutated transaction after VM execution.
sourcepub const fn receipts(&self) -> &[Receipt]
pub const fn receipts(&self) -> &[Receipt]
Transaction receipts representing the state transition.
sourcepub fn should_revert(&self) -> bool
pub fn should_revert(&self) -> bool
Flag whether the client should revert after execution.
sourcepub fn into_owned(self) -> StateTransition
pub fn into_owned(self) -> StateTransition
Convert this instance into an owned state transition, cloning its internals.
Trait Implementations
sourceimpl<'a> Clone for StateTransitionRef<'a>
impl<'a> Clone for StateTransitionRef<'a>
sourcefn clone(&self) -> StateTransitionRef<'a>
fn clone(&self) -> StateTransitionRef<'a>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<'a> Debug for StateTransitionRef<'a>
impl<'a> Debug for StateTransitionRef<'a>
sourceimpl<'a> From<&'a StateTransition> for StateTransitionRef<'a>
impl<'a> From<&'a StateTransition> for StateTransitionRef<'a>
sourcefn from(t: &'a StateTransition) -> StateTransitionRef<'a>
fn from(t: &'a StateTransition) -> StateTransitionRef<'a>
Converts to this type from the input type.
sourceimpl<'a> From<StateTransitionRef<'a>> for ProgramState
impl<'a> From<StateTransitionRef<'a>> for ProgramState
sourcefn from(t: StateTransitionRef<'a>) -> ProgramState
fn from(t: StateTransitionRef<'a>) -> ProgramState
Converts to this type from the input type.
sourceimpl<'a> PartialEq<StateTransitionRef<'a>> for StateTransitionRef<'a>
impl<'a> PartialEq<StateTransitionRef<'a>> for StateTransitionRef<'a>
sourcefn eq(&self, other: &StateTransitionRef<'a>) -> bool
fn eq(&self, other: &StateTransitionRef<'a>) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &StateTransitionRef<'a>) -> bool
fn ne(&self, other: &StateTransitionRef<'a>) -> bool
This method tests for !=
.
impl<'a> Copy for StateTransitionRef<'a>
impl<'a> Eq for StateTransitionRef<'a>
impl<'a> StructuralEq for StateTransitionRef<'a>
impl<'a> StructuralPartialEq for StateTransitionRef<'a>
Auto Trait Implementations
impl<'a> RefUnwindSafe for StateTransitionRef<'a>
impl<'a> Send for StateTransitionRef<'a>
impl<'a> Sync for StateTransitionRef<'a>
impl<'a> Unpin for StateTransitionRef<'a>
impl<'a> UnwindSafe for StateTransitionRef<'a>
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