Struct sputnikvm::M256 [] [src]

pub struct M256(pub U256);

Represent an unsigned modulo 256-bit integer

Methods

impl M256
[src]

Zero value of M256,

One value of M256,

Maximum value of M256,

Minimum value of M256,

Bits required to represent this value.

Equals floor(log2(*)). This is always an integer.

Conversion to u32 with overflow checking

Panics

Panics if the number is larger than 232.

Conversion to u64 with overflow checking

Panics

Panics if the number is larger than 264.

Conversion to usize with overflow checking

Panics

Panics if the number is larger than usize::max_value().

Return specific byte.

Panics

Panics if index exceeds the byte width of the number.

Return specific byte in big-endian format.

Panics

Panics if index exceeds the byte width of the number.

Trait Implementations

impl Clone for M256
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl PartialOrd<M256> for M256
[src]

impl Into<u64> for M256
[src]

Performs the conversion.

impl Into<U256> for M256
[src]

Performs the conversion.

impl Into<U512> for M256
[src]

Performs the conversion.

impl Default for M256
[src]

Returns the "default value" for a type. Read more

impl BitOr<M256> for M256
[src]

The resulting type after applying the | operator

The method for the | operator

impl Copy for M256
[src]

impl Add<M256> for M256
[src]

The resulting type after applying the + operator

The method for the + operator

impl Div<M256> for M256
[src]

The resulting type after applying the / operator

The method for the / operator

impl Ord for M256
[src]

impl Rem<M256> for M256
[src]

The resulting type after applying the % operator

The method for the % operator

impl Mul<M256> for M256
[src]

The resulting type after applying the * operator

The method for the * operator

impl PartialEq<M256> for M256
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Decodable for M256
[src]

impl Sub<M256> for M256
[src]

The resulting type after applying the - operator

The method for the - operator

impl LowerHex for M256
[src]

impl UpperHex for M256
[src]

impl BitAnd<M256> for M256
[src]

The resulting type after applying the & operator

The method for the & operator

impl FromStr for M256
[src]

The associated error which can be returned from parsing.

Parses a string s to return a value of this type. Read more

impl From<u64> for M256
[src]

Performs the conversion.

impl<'a> From<&'a [u8]> for M256
[src]

Performs the conversion.

impl From<i32> for M256
[src]

Performs the conversion.

impl From<H160> for M256
[src]

Performs the conversion.

impl From<U256> for M256
[src]

Performs the conversion.

impl From<bool> for M256
[src]

Performs the conversion.

impl From<H256> for M256
[src]

Performs the conversion.

impl From<usize> for M256
[src]

Performs the conversion.

impl From<U512> for M256
[src]

Performs the conversion.

impl Shl<usize> for M256
[src]

impl Shr<usize> for M256
[src]

impl BitXor<M256> for M256
[src]

The resulting type after applying the ^ operator

The method for the ^ operator

impl Eq for M256
[src]

impl Hash for M256
[src]

impl Encodable for M256
[src]

impl Not for M256
[src]

impl Debug for M256
[src]

Formats the value using the given formatter.