Struct bigint::M256 [] [src]

pub struct M256(pub U256);

Represent an unsigned modulo 256-bit integer

Methods

impl M256
[src]

[src]

Zero value of M256,

[src]

One value of M256,

[src]

Maximum value of M256,

[src]

Minimum value of M256,

[src]

Bits required to represent this value.

[src]

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

[src]

Conversion to u32 with overflow checking

Panics

Panics if the number is larger than 232.

[src]

Conversion to u64 with overflow checking

Panics

Panics if the number is larger than 264.

[src]

Conversion to usize with overflow checking

Panics

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

[src]

Return specific byte.

Panics

Panics if index exceeds the byte width of the number.

[src]

Return specific byte in big-endian format.

Panics

Panics if index exceeds the byte width of the number.

Trait Implementations

impl Eq for M256
[src]

impl PartialEq for M256
[src]

[src]

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

[src]

This method tests for !=.

impl Debug for M256
[src]

[src]

Formats the value using the given formatter.

impl Copy for M256
[src]

impl Clone for M256
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Hash for M256
[src]

[src]

Feeds this value into the given [Hasher]. Read more

1.3.0
[src]

Feeds a slice of this type into the given [Hasher]. Read more

impl Default for M256
[src]

[src]

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

impl FromStr for M256
[src]

The associated error which can be returned from parsing.

[src]

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

impl Encodable for M256
[src]

[src]

Append a value to the stream

[src]

Get rlp-encoded bytes for this instance

impl Decodable for M256
[src]

[src]

Decode a value from RLP bytes

impl From<u64> for M256
[src]

[src]

Performs the conversion.

impl Into<u64> for M256
[src]

[src]

Performs the conversion.

impl From<usize> for M256
[src]

[src]

Performs the conversion.

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

[src]

Performs the conversion.

impl From<bool> for M256
[src]

[src]

Performs the conversion.

impl From<U256> for M256
[src]

[src]

Performs the conversion.

impl Into<U256> for M256
[src]

[src]

Performs the conversion.

impl From<U512> for M256
[src]

[src]

Performs the conversion.

impl Into<U512> for M256
[src]

[src]

Performs the conversion.

impl From<i32> for M256
[src]

[src]

Performs the conversion.

impl From<H256> for M256
[src]

[src]

Performs the conversion.

impl From<H160> for M256
[src]

[src]

Performs the conversion.

impl Ord for M256
[src]

[src]

This method returns an Ordering between self and other. Read more

1.22.0
[src]

Compares and returns the maximum of two values. Read more

1.22.0
[src]

Compares and returns the minimum of two values. Read more

impl PartialOrd for M256
[src]

[src]

This method returns an ordering between self and other values if one exists. Read more

1.0.0
[src]

This method tests less than (for self and other) and is used by the < operator. Read more

1.0.0
[src]

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

1.0.0
[src]

This method tests greater than (for self and other) and is used by the > operator. Read more

1.0.0
[src]

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl BitAnd<M256> for M256
[src]

The resulting type after applying the & operator.

[src]

Performs the & operation.

impl BitOr<M256> for M256
[src]

The resulting type after applying the | operator.

[src]

Performs the | operation.

impl BitXor<M256> for M256
[src]

The resulting type after applying the ^ operator.

[src]

Performs the ^ operation.

impl Shl<usize> for M256
[src]

The resulting type after applying the << operator.

[src]

Performs the << operation.

impl Shr<usize> for M256
[src]

The resulting type after applying the >> operator.

[src]

Performs the >> operation.

impl Add<M256> for M256
[src]

The resulting type after applying the + operator.

[src]

Performs the + operation.

impl Sub<M256> for M256
[src]

The resulting type after applying the - operator.

[src]

Performs the - operation.

impl Mul<M256> for M256
[src]

The resulting type after applying the * operator.

[src]

Performs the * operation.

impl Div for M256
[src]

The resulting type after applying the / operator.

[src]

Performs the / operation.

impl Rem for M256
[src]

The resulting type after applying the % operator.

[src]

Performs the % operation.

impl Not for M256
[src]

The resulting type after applying the ! operator.

[src]

Performs the unary ! operation.

impl LowerHex for M256
[src]

[src]

Formats the value using the given formatter.

impl UpperHex for M256
[src]

[src]

Formats the value using the given formatter.