[−][src]Struct evm_gasometer::Gasometer
Methods
impl<'config> Gasometer<'config>
[src]
pub fn new(gas_limit: usize, config: &'config Config) -> Self
[src]
pub fn config(&self) -> &'config Config
[src]
pub fn gas(&self) -> usize
[src]
pub fn total_used_gas(&self) -> usize
[src]
pub fn refunded_gas(&self) -> isize
[src]
pub fn fail(&mut self) -> ExitError
[src]
pub fn record_cost(&mut self, cost: usize) -> Result<(), ExitError>
[src]
pub fn record_refund(&mut self, refund: isize) -> Result<(), ExitError>
[src]
pub fn record_deposit(&mut self, len: usize) -> Result<(), ExitError>
[src]
pub fn record_opcode(
&mut self,
cost: GasCost,
memory: Option<MemoryCost>
) -> Result<(), ExitError>
[src]
&mut self,
cost: GasCost,
memory: Option<MemoryCost>
) -> Result<(), ExitError>
pub fn record_stipend(&mut self, stipend: usize) -> Result<(), ExitError>
[src]
pub fn record_transaction(
&mut self,
cost: TransactionCost
) -> Result<(), ExitError>
[src]
&mut self,
cost: TransactionCost
) -> Result<(), ExitError>
Trait Implementations
Auto Trait Implementations
impl<'config> RefUnwindSafe for Gasometer<'config>
impl<'config> Send for Gasometer<'config>
impl<'config> Sync for Gasometer<'config>
impl<'config> Unpin for Gasometer<'config>
impl<'config> UnwindSafe for Gasometer<'config>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,