Struct sputnikvm::Gas
[−]
[src]
pub struct Gas(_);
Methods
impl Gas
[src]
fn zero() -> Gas
Zero value of Gas,
fn one() -> Gas
One value of Gas,
fn max_value() -> Gas
Maximum value of Gas,
fn min_value() -> Gas
Minimum value of Gas,
fn bits(self) -> usize
Bits required to represent this value.
fn log2floor(self) -> usize
Equals floor(log2(*))
. This is always an integer.
fn as_u32(&self) -> u32
fn as_u64(&self) -> u64
fn as_usize(&self) -> usize
Conversion to usize with overflow checking
Panics
Panics if the number is larger than usize::max_value().
Trait Implementations
impl Clone for Gas
[src]
fn clone(&self) -> Gas
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl PartialOrd<Gas> for Gas
[src]
fn partial_cmp(&self, other: &Gas) -> Option<Ordering>
impl Into<M256> for Gas
[src]
impl Into<U256> for Gas
[src]
impl Into<u64> for Gas
[src]
impl LowerHex for Gas
[src]
impl Default for Gas
[src]
impl FromStr for Gas
[src]
type Err = ParseHexError
The associated error which can be returned from parsing.
fn from_str(s: &str) -> Result<Gas, ParseHexError>
Parses a string s
to return a value of this type. Read more
impl Eq for Gas
[src]
impl Copy for Gas
[src]
impl Ord for Gas
[src]
impl Mul<Gas> for Gas
[src]
type Output = Gas
The resulting type after applying the *
operator
fn mul(self, other: Gas) -> Gas
The method for the *
operator
impl Debug for Gas
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter.
impl Sub<Gas> for Gas
[src]
type Output = Gas
The resulting type after applying the -
operator
fn sub(self, other: Gas) -> Gas
The method for the -
operator
impl Decodable for Gas
[src]
fn decode(rlp: &UntrustedRlp) -> Result<Gas, DecoderError>
impl Add<Gas> for Gas
[src]
type Output = Gas
The resulting type after applying the +
operator
fn add(self, other: Gas) -> Gas
The method for the +
operator
impl Div<Gas> for Gas
[src]
type Output = Gas
The resulting type after applying the /
operator
fn div(self, other: Gas) -> Gas
The method for the /
operator
impl Rem<Gas> for Gas
[src]
type Output = Gas
The resulting type after applying the %
operator
fn rem(self, other: Gas) -> Gas
The method for the %
operator
impl From<usize> for Gas
[src]
impl From<U256> for Gas
[src]
impl<'a> From<&'a [u8]> for Gas
[src]
impl From<u64> for Gas
[src]
impl From<M256> for Gas
[src]
impl From<bool> for Gas
[src]
impl UpperHex for Gas
[src]
impl PartialEq<Gas> for Gas
[src]
fn eq(&self, __arg_0: &Gas) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Gas) -> bool
This method tests for !=
.