pub struct DebugInfo { /* private fields */ }
Expand description
Recorder for relevant interactions with this crate.
Implementations§
Source§impl DebugInfo
impl DebugInfo
pub fn new() -> Self
Sourcepub fn inc_writes(&mut self, addr: Address)
pub fn inc_writes(&mut self, addr: Address)
Increases the number of storage writes for the supplied account by one.
Sourcepub fn inc_reads(&mut self, addr: Address)
pub fn inc_reads(&mut self, addr: Address)
Increases the number of storage reads for the supplied account by one.
Sourcepub fn record_cell_for_account(&mut self, addr: Address, key: Vec<u8>)
pub fn record_cell_for_account(&mut self, addr: Address, key: Vec<u8>)
Records that a cell exists for an account under key
.
Calling this function multiple times won’t change the fact that only one cell is recorded.
Sourcepub fn remove_cell_for_account(
&mut self,
addr: Address,
key: Vec<u8>,
) -> Option<bool>
pub fn remove_cell_for_account( &mut self, addr: Address, key: Vec<u8>, ) -> Option<bool>
Removes the cell under key
for the supplied account.
Returns the removed cell, if there was one.
Sourcepub fn record_event(&mut self, event: EmittedEvent)
pub fn record_event(&mut self, event: EmittedEvent)
Records an event.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DebugInfo
impl RefUnwindSafe for DebugInfo
impl Send for DebugInfo
impl Sync for DebugInfo
impl Unpin for DebugInfo
impl UnwindSafe for DebugInfo
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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§impl<T, Outer> IsWrappedBy<Outer> for T
impl<T, Outer> IsWrappedBy<Outer> for T
§impl<T> SaturatedConversion for T
impl<T> SaturatedConversion for T
§fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
§fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
Consume self to return an equivalent value of
T
. Read more§impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
§fn unchecked_into(self) -> T
fn unchecked_into(self) -> T
The counterpart to
unchecked_from
.§impl<T, S> UniqueSaturatedInto<T> for S
impl<T, S> UniqueSaturatedInto<T> for S
§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
Consume self to return an equivalent value of
T
.