Struct everscale_types::num::Uint15
source · #[repr(transparent)]pub struct Uint15(_);Expand description
Fixed-length 15-bit integer.
Implementations§
source§impl Uint15
impl Uint15
sourcepub const fn into_inner(self) -> u16
pub const fn into_inner(self) -> u16
Converts integer into an underlying primitive integer.
sourcepub const fn is_valid(&self) -> bool
pub const fn is_valid(&self) -> bool
Returns true if an underlying primitive integer fits into the repr.
sourcepub const fn checked_add(self, rhs: Self) -> Option<Self>
pub const fn checked_add(self, rhs: Self) -> Option<Self>
Checked integer addition. Computes self + rhs, returning None if overflow occurred.
sourcepub const fn checked_sub(self, rhs: Self) -> Option<Self>
pub const fn checked_sub(self, rhs: Self) -> Option<Self>
Checked integer subtraction. Computes self - rhs, returning None if overflow occurred.
sourcepub const fn checked_mul(self, rhs: Self) -> Option<Self>
pub const fn checked_mul(self, rhs: Self) -> Option<Self>
Checked integer multiplication. Computes self * rhs, returning None if overflow occurred.
sourcepub const fn checked_div(self, rhs: Self) -> Option<Self>
pub const fn checked_div(self, rhs: Self) -> Option<Self>
Checked integer division. Computes self / rhs, returning None if rhs == 0
or overflow occurred.
Trait Implementations§
source§impl AddAssign<Uint15> for Uint15
impl AddAssign<Uint15> for Uint15
source§fn add_assign(&mut self, rhs: Self)
fn add_assign(&mut self, rhs: Self)
Performs the
+= operation. Read moresource§impl AddAssign<u16> for Uint15
impl AddAssign<u16> for Uint15
source§fn add_assign(&mut self, rhs: u16)
fn add_assign(&mut self, rhs: u16)
Performs the
+= operation. Read moresource§impl DivAssign<Uint15> for Uint15
impl DivAssign<Uint15> for Uint15
source§fn div_assign(&mut self, rhs: Self)
fn div_assign(&mut self, rhs: Self)
Performs the
/= operation. Read moresource§impl DivAssign<u16> for Uint15
impl DivAssign<u16> for Uint15
source§fn div_assign(&mut self, rhs: u16)
fn div_assign(&mut self, rhs: u16)
Performs the
/= operation. Read moresource§impl<'a, C: CellFamily> Load<'a, C> for Uint15
impl<'a, C: CellFamily> Load<'a, C> for Uint15
source§impl MulAssign<Uint15> for Uint15
impl MulAssign<Uint15> for Uint15
source§fn mul_assign(&mut self, rhs: Self)
fn mul_assign(&mut self, rhs: Self)
Performs the
*= operation. Read moresource§impl MulAssign<u16> for Uint15
impl MulAssign<u16> for Uint15
source§fn mul_assign(&mut self, rhs: u16)
fn mul_assign(&mut self, rhs: u16)
Performs the
*= operation. Read moresource§impl Ord for Uint15
impl Ord for Uint15
source§impl PartialEq<Uint15> for Uint15
impl PartialEq<Uint15> for Uint15
source§impl PartialEq<Uint15> for u16
impl PartialEq<Uint15> for u16
source§impl PartialOrd<Uint15> for Uint15
impl PartialOrd<Uint15> for Uint15
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moresource§impl ShlAssign<u8> for Uint15
impl ShlAssign<u8> for Uint15
source§fn shl_assign(&mut self, rhs: u8)
fn shl_assign(&mut self, rhs: u8)
Performs the
<<= operation. Read moresource§impl ShrAssign<u8> for Uint15
impl ShrAssign<u8> for Uint15
source§fn shr_assign(&mut self, rhs: u8)
fn shr_assign(&mut self, rhs: u8)
Performs the
>>= operation. Read moresource§impl<C: CellFamily> Store<C> for Uint15
impl<C: CellFamily> Store<C> for Uint15
source§fn store_into(
&self,
builder: &mut CellBuilder<C>,
_: &mut dyn Finalizer<C>
) -> bool
fn store_into( &self, builder: &mut CellBuilder<C>, _: &mut dyn Finalizer<C> ) -> bool
Tries to store itself into the cell builder.
source§impl SubAssign<Uint15> for Uint15
impl SubAssign<Uint15> for Uint15
source§fn sub_assign(&mut self, rhs: Self)
fn sub_assign(&mut self, rhs: Self)
Performs the
-= operation. Read moresource§impl SubAssign<u16> for Uint15
impl SubAssign<u16> for Uint15
source§fn sub_assign(&mut self, rhs: u16)
fn sub_assign(&mut self, rhs: u16)
Performs the
-= operation. Read more