[−][src]Struct cosmwasm_std::Uint128
Implementations
impl Uint128
[src]
pub const fn zero() -> Self
[src]
Creates a Uint128(0)
pub fn u128(&self) -> u128
[src]
Returns a copy of the internal data
pub fn is_zero(&self) -> bool
[src]
impl Uint128
[src]
pub fn multiply_ratio<A: Into<u128>, B: Into<u128>>(
&self,
nom: A,
denom: B
) -> Uint128
[src]
&self,
nom: A,
denom: B
) -> Uint128
returns self * nom / denom
Trait Implementations
impl Add<Uint128> for Uint128
[src]
type Output = Self
The resulting type after applying the +
operator.
fn add(self, other: Self) -> Self
[src]
impl AddAssign<Uint128> for Uint128
[src]
fn add_assign(&mut self, other: Self)
[src]
impl Clone for Uint128
[src]
impl Copy for Uint128
[src]
impl Debug for Uint128
[src]
impl Default for Uint128
[src]
impl<'de> Deserialize<'de> for Uint128
[src]
Deserializes as a base64 string
fn deserialize<D>(deserializer: D) -> Result<Uint128, D::Error> where
D: Deserializer<'de>,
[src]
D: Deserializer<'de>,
impl Display for Uint128
[src]
impl Eq for Uint128
[src]
impl From<u128> for Uint128
[src]
impl From<u64> for Uint128
[src]
impl Into<String> for Uint128
[src]
impl Into<u128> for Uint128
[src]
impl JsonSchema for Uint128
[src]
fn schema_name() -> String
[src]
fn json_schema(gen: &mut SchemaGenerator) -> Schema
[src]
fn is_referenceable() -> bool
[src]
impl Mul<Decimal> for Uint128
[src]
Both du and ud with d: Decimal and u: Uint128 returns an Uint128. There is no specific reason for this decision other than the initial use cases we have. If you need a Decimal result for the same calculation, use Decimal(du) or Decimal(ud).
type Output = Self
The resulting type after applying the *
operator.
fn mul(self, rhs: Decimal) -> Self::Output
[src]
impl Mul<Uint128> for Decimal
[src]
type Output = Uint128
The resulting type after applying the *
operator.
fn mul(self, rhs: Uint128) -> Self::Output
[src]
impl Ord for Uint128
[src]
fn cmp(&self, other: &Uint128) -> Ordering
[src]
#[must_use]fn max(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn min(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn clamp(self, min: Self, max: Self) -> Self
[src]
impl PartialEq<Uint128> for Uint128
[src]
impl PartialOrd<Uint128> for Uint128
[src]
fn partial_cmp(&self, other: &Uint128) -> Option<Ordering>
[src]
fn lt(&self, other: &Uint128) -> bool
[src]
fn le(&self, other: &Uint128) -> bool
[src]
fn gt(&self, other: &Uint128) -> bool
[src]
fn ge(&self, other: &Uint128) -> bool
[src]
impl Serialize for Uint128
[src]
Serializes as a base64 string
impl StructuralEq for Uint128
[src]
impl StructuralPartialEq for Uint128
[src]
impl Sub<Uint128> for Uint128
[src]
type Output = StdResult<Self>
The resulting type after applying the -
operator.
fn sub(self, other: Self) -> StdResult<Self>
[src]
impl<'_> TryFrom<&'_ str> for Uint128
[src]
Auto Trait Implementations
impl RefUnwindSafe for Uint128
impl Send for Uint128
impl Sync for Uint128
impl Unpin for Uint128
impl UnwindSafe for Uint128
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,