Struct amplify::num::u256 [−][src]
pub struct u256(_);
Little-endian large integer type
Implementations
impl u256
[src]
impl u256
[src]pub fn as_mut_ptr(&mut self) -> *mut u64
[src]
pub fn as_mut_ptr(&mut self) -> *mut u64
[src]Converts the object to a mutable raw pointer
pub fn as_array(&self) -> &[u64; 4]
[src]
pub fn as_array(&self) -> &[u64; 4]
[src]Returns the underlying array of words constituting large integer
pub fn to_array(&self) -> [u64; 4]
[src]
pub fn to_array(&self) -> [u64; 4]
[src]Returns the underlying array of words constituting large integer
pub fn into_array(self) -> [u64; 4]
[src]
pub fn into_array(self) -> [u64; 4]
[src]Returns the underlying array of words constituting large integer
pub fn from_array(array: [u64; 4]) -> Self
[src]
pub fn from_array(array: [u64; 4]) -> Self
[src]Constructs integer type from the underlying array of words.
impl u256
[src]
impl u256
[src]pub fn from_u64(init: u64) -> Option<u256>
[src]
pub fn from_u64(init: u64) -> Option<u256>
[src]Create an object from a given unsigned 64-bit integer
pub fn from_be_bytes(bytes: [u8; 32]) -> u256
[src]
pub fn from_be_bytes(bytes: [u8; 32]) -> u256
[src]Creates the integer value from a byte array using big-endian encoding
pub fn from_be_slice(bytes: &[u8]) -> Result<u256, ParseLengthError>
[src]
pub fn from_be_slice(bytes: &[u8]) -> Result<u256, ParseLengthError>
[src]Creates the integer value from a byte slice using big-endian encoding
pub fn from_le_bytes(bytes: [u8; 32]) -> u256
[src]
pub fn from_le_bytes(bytes: [u8; 32]) -> u256
[src]Creates the integer value from a byte array using little-endian encoding
pub fn from_le_slice(bytes: &[u8]) -> Result<u256, ParseLengthError>
[src]
pub fn from_le_slice(bytes: &[u8]) -> Result<u256, ParseLengthError>
[src]Creates the integer value from a byte slice using little-endian encoding
pub fn to_be_bytes(&self) -> [u8; 32]
[src]
pub fn to_be_bytes(&self) -> [u8; 32]
[src]Convert the integer into a byte array using big-endian encoding
pub fn to_le_bytes(&self) -> [u8; 32]
[src]
pub fn to_le_bytes(&self) -> [u8; 32]
[src]Convert a integer into a byte array using lottle-endian encoding
Trait Implementations
impl BitArray for u256
[src]
impl BitArray for u256
[src]impl Ord for u256
[src]
impl Ord for u256
[src]impl PartialOrd<u256> for u256
[src]
impl PartialOrd<u256> for u256
[src]fn partial_cmp(&self, other: &u256) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &u256) -> Option<Ordering>
[src]This method returns an ordering between self
and other
values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Copy for u256
[src]
impl Eq for u256
[src]
impl StructuralEq for u256
[src]
impl StructuralPartialEq for u256
[src]
Auto Trait Implementations
impl RefUnwindSafe for u256
impl Send for u256
impl Sync for u256
impl Unpin for u256
impl UnwindSafe for u256
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more