Struct amplify::num::u24 [−][src]
pub struct u24(_);
Expand description
24-bit unsigned integer in the range 0..16_777_216
Implementations
Methods from Deref<Target = u32>
pub const MIN: u32
1.43.0[src]
pub const MAX: u32
1.43.0[src]
pub const BITS: u32
1.53.0[src]
pub fn as_ne_bytes(&self) -> &[u8; 4]
[src]
🔬 This is a nightly-only experimental API. (num_as_ne_bytes
)
pub fn as_ne_bytes(&self) -> &[u8; 4]
[src]num_as_ne_bytes
)Return the memory representation of this integer as a byte array in native byte order.
to_ne_bytes
should be preferred over this whenever possible.
Examples
#![feature(num_as_ne_bytes)] let num = 0x12345678u32; let bytes = num.as_ne_bytes(); assert_eq!( bytes, if cfg!(target_endian = "big") { &[0x12, 0x34, 0x56, 0x78] } else { &[0x78, 0x56, 0x34, 0x12] } );
Trait Implementations
impl AddAssign<&'_ u24> for u24
[src]
impl AddAssign<&'_ u24> for u24
[src]fn add_assign(&mut self, rhs: &u24)
[src]
fn add_assign(&mut self, rhs: &u24)
[src]Performs the +=
operation. Read more
impl AddAssign<&'_ u32> for u24
[src]
impl AddAssign<&'_ u32> for u24
[src]fn add_assign(&mut self, rhs: &u32)
[src]
fn add_assign(&mut self, rhs: &u32)
[src]Performs the +=
operation. Read more
impl AddAssign<u24> for u24
[src]
impl AddAssign<u24> for u24
[src]fn add_assign(&mut self, rhs: Self)
[src]
fn add_assign(&mut self, rhs: Self)
[src]Performs the +=
operation. Read more
impl AddAssign<u32> for u24
[src]
impl AddAssign<u32> for u24
[src]fn add_assign(&mut self, rhs: u32)
[src]
fn add_assign(&mut self, rhs: u32)
[src]Performs the +=
operation. Read more
impl BitAndAssign<&'_ u24> for u24
[src]
impl BitAndAssign<&'_ u24> for u24
[src]fn bitand_assign(&mut self, rhs: &u24)
[src]
fn bitand_assign(&mut self, rhs: &u24)
[src]Performs the &=
operation. Read more
impl BitAndAssign<&'_ u32> for u24
[src]
impl BitAndAssign<&'_ u32> for u24
[src]fn bitand_assign(&mut self, rhs: &u32)
[src]
fn bitand_assign(&mut self, rhs: &u32)
[src]Performs the &=
operation. Read more
impl BitAndAssign<u24> for u24
[src]
impl BitAndAssign<u24> for u24
[src]fn bitand_assign(&mut self, rhs: Self)
[src]
fn bitand_assign(&mut self, rhs: Self)
[src]Performs the &=
operation. Read more
impl BitAndAssign<u32> for u24
[src]
impl BitAndAssign<u32> for u24
[src]fn bitand_assign(&mut self, rhs: u32)
[src]
fn bitand_assign(&mut self, rhs: u32)
[src]Performs the &=
operation. Read more
impl BitOrAssign<&'_ u24> for u24
[src]
impl BitOrAssign<&'_ u24> for u24
[src]fn bitor_assign(&mut self, rhs: &u24)
[src]
fn bitor_assign(&mut self, rhs: &u24)
[src]Performs the |=
operation. Read more
impl BitOrAssign<&'_ u32> for u24
[src]
impl BitOrAssign<&'_ u32> for u24
[src]fn bitor_assign(&mut self, rhs: &u32)
[src]
fn bitor_assign(&mut self, rhs: &u32)
[src]Performs the |=
operation. Read more
impl BitOrAssign<u24> for u24
[src]
impl BitOrAssign<u24> for u24
[src]fn bitor_assign(&mut self, rhs: Self)
[src]
fn bitor_assign(&mut self, rhs: Self)
[src]Performs the |=
operation. Read more
impl BitOrAssign<u32> for u24
[src]
impl BitOrAssign<u32> for u24
[src]fn bitor_assign(&mut self, rhs: u32)
[src]
fn bitor_assign(&mut self, rhs: u32)
[src]Performs the |=
operation. Read more
impl BitXorAssign<&'_ u24> for u24
[src]
impl BitXorAssign<&'_ u24> for u24
[src]fn bitxor_assign(&mut self, rhs: &u24)
[src]
fn bitxor_assign(&mut self, rhs: &u24)
[src]Performs the ^=
operation. Read more
impl BitXorAssign<&'_ u32> for u24
[src]
impl BitXorAssign<&'_ u32> for u24
[src]fn bitxor_assign(&mut self, rhs: &u32)
[src]
fn bitxor_assign(&mut self, rhs: &u32)
[src]Performs the ^=
operation. Read more
impl BitXorAssign<u24> for u24
[src]
impl BitXorAssign<u24> for u24
[src]fn bitxor_assign(&mut self, rhs: Self)
[src]
fn bitxor_assign(&mut self, rhs: Self)
[src]Performs the ^=
operation. Read more
impl BitXorAssign<u32> for u24
[src]
impl BitXorAssign<u32> for u24
[src]fn bitxor_assign(&mut self, rhs: u32)
[src]
fn bitxor_assign(&mut self, rhs: u32)
[src]Performs the ^=
operation. Read more
impl DivAssign<&'_ u24> for u24
[src]
impl DivAssign<&'_ u24> for u24
[src]fn div_assign(&mut self, rhs: &u24)
[src]
fn div_assign(&mut self, rhs: &u24)
[src]Performs the /=
operation. Read more
impl DivAssign<&'_ u32> for u24
[src]
impl DivAssign<&'_ u32> for u24
[src]fn div_assign(&mut self, rhs: &u32)
[src]
fn div_assign(&mut self, rhs: &u32)
[src]Performs the /=
operation. Read more
impl DivAssign<u24> for u24
[src]
impl DivAssign<u24> for u24
[src]fn div_assign(&mut self, rhs: Self)
[src]
fn div_assign(&mut self, rhs: Self)
[src]Performs the /=
operation. Read more
impl DivAssign<u32> for u24
[src]
impl DivAssign<u32> for u24
[src]fn div_assign(&mut self, rhs: u32)
[src]
fn div_assign(&mut self, rhs: u32)
[src]Performs the /=
operation. Read more
impl MulAssign<&'_ u24> for u24
[src]
impl MulAssign<&'_ u24> for u24
[src]fn mul_assign(&mut self, rhs: &u24)
[src]
fn mul_assign(&mut self, rhs: &u24)
[src]Performs the *=
operation. Read more
impl MulAssign<&'_ u32> for u24
[src]
impl MulAssign<&'_ u32> for u24
[src]fn mul_assign(&mut self, rhs: &u32)
[src]
fn mul_assign(&mut self, rhs: &u32)
[src]Performs the *=
operation. Read more
impl MulAssign<u24> for u24
[src]
impl MulAssign<u24> for u24
[src]fn mul_assign(&mut self, rhs: Self)
[src]
fn mul_assign(&mut self, rhs: Self)
[src]Performs the *=
operation. Read more
impl MulAssign<u32> for u24
[src]
impl MulAssign<u32> for u24
[src]fn mul_assign(&mut self, rhs: u32)
[src]
fn mul_assign(&mut self, rhs: u32)
[src]Performs the *=
operation. Read more
impl Ord for u24
[src]
impl Ord for u24
[src]impl PartialOrd<u24> for u24
[src]
impl PartialOrd<u24> for u24
[src]fn partial_cmp(&self, other: &u24) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &u24) -> 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 RemAssign<&'_ u24> for u24
[src]
impl RemAssign<&'_ u24> for u24
[src]fn rem_assign(&mut self, rhs: &u24)
[src]
fn rem_assign(&mut self, rhs: &u24)
[src]Performs the %=
operation. Read more
impl RemAssign<&'_ u32> for u24
[src]
impl RemAssign<&'_ u32> for u24
[src]fn rem_assign(&mut self, rhs: &u32)
[src]
fn rem_assign(&mut self, rhs: &u32)
[src]Performs the %=
operation. Read more
impl RemAssign<u24> for u24
[src]
impl RemAssign<u24> for u24
[src]fn rem_assign(&mut self, rhs: Self)
[src]
fn rem_assign(&mut self, rhs: Self)
[src]Performs the %=
operation. Read more
impl RemAssign<u32> for u24
[src]
impl RemAssign<u32> for u24
[src]fn rem_assign(&mut self, rhs: u32)
[src]
fn rem_assign(&mut self, rhs: u32)
[src]Performs the %=
operation. Read more
impl ShlAssign<&'_ u24> for u24
[src]
impl ShlAssign<&'_ u24> for u24
[src]fn shl_assign(&mut self, rhs: &u24)
[src]
fn shl_assign(&mut self, rhs: &u24)
[src]Performs the <<=
operation. Read more
impl ShlAssign<&'_ u32> for u24
[src]
impl ShlAssign<&'_ u32> for u24
[src]fn shl_assign(&mut self, rhs: &u32)
[src]
fn shl_assign(&mut self, rhs: &u32)
[src]Performs the <<=
operation. Read more
impl ShlAssign<u24> for u24
[src]
impl ShlAssign<u24> for u24
[src]fn shl_assign(&mut self, rhs: Self)
[src]
fn shl_assign(&mut self, rhs: Self)
[src]Performs the <<=
operation. Read more
impl ShlAssign<u32> for u24
[src]
impl ShlAssign<u32> for u24
[src]fn shl_assign(&mut self, rhs: u32)
[src]
fn shl_assign(&mut self, rhs: u32)
[src]Performs the <<=
operation. Read more
impl ShrAssign<&'_ u24> for u24
[src]
impl ShrAssign<&'_ u24> for u24
[src]fn shr_assign(&mut self, rhs: &u24)
[src]
fn shr_assign(&mut self, rhs: &u24)
[src]Performs the >>=
operation. Read more
impl ShrAssign<&'_ u32> for u24
[src]
impl ShrAssign<&'_ u32> for u24
[src]fn shr_assign(&mut self, rhs: &u32)
[src]
fn shr_assign(&mut self, rhs: &u32)
[src]Performs the >>=
operation. Read more
impl ShrAssign<u24> for u24
[src]
impl ShrAssign<u24> for u24
[src]fn shr_assign(&mut self, rhs: Self)
[src]
fn shr_assign(&mut self, rhs: Self)
[src]Performs the >>=
operation. Read more
impl ShrAssign<u32> for u24
[src]
impl ShrAssign<u32> for u24
[src]fn shr_assign(&mut self, rhs: u32)
[src]
fn shr_assign(&mut self, rhs: u32)
[src]Performs the >>=
operation. Read more
impl SubAssign<&'_ u24> for u24
[src]
impl SubAssign<&'_ u24> for u24
[src]fn sub_assign(&mut self, rhs: &u24)
[src]
fn sub_assign(&mut self, rhs: &u24)
[src]Performs the -=
operation. Read more
impl SubAssign<&'_ u32> for u24
[src]
impl SubAssign<&'_ u32> for u24
[src]fn sub_assign(&mut self, rhs: &u32)
[src]
fn sub_assign(&mut self, rhs: &u32)
[src]Performs the -=
operation. Read more
impl SubAssign<u24> for u24
[src]
impl SubAssign<u24> for u24
[src]fn sub_assign(&mut self, rhs: Self)
[src]
fn sub_assign(&mut self, rhs: Self)
[src]Performs the -=
operation. Read more
impl SubAssign<u32> for u24
[src]
impl SubAssign<u32> for u24
[src]fn sub_assign(&mut self, rhs: u32)
[src]
fn sub_assign(&mut self, rhs: u32)
[src]Performs the -=
operation. Read more
impl Copy for u24
[src]
impl Eq for u24
[src]
impl StructuralEq for u24
[src]
impl StructuralPartialEq for u24
[src]
Auto Trait Implementations
impl RefUnwindSafe for u24
impl Send for u24
impl Sync for u24
impl Unpin for u24
impl UnwindSafe for u24
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