Struct decimal_rs::Decimal[][src]

pub struct Decimal { /* fields omitted */ }
Expand description

High precision decimal.

Implementations

impl Decimal[src]

pub const ZERO: Decimal[src]

Zero value, i.e. 0.

pub const ONE: Decimal[src]

i.e. 1.

pub const unsafe fn from_parts_unchecked(
    int_val: u128,
    scale: i16,
    negative: bool
) -> Decimal
[src]

Creates a Decimal from parts without boundary checking.

Safety

User have to guarantee that int_val has at most 38 tens digits and scale ranges from [-126, 130].

pub const fn from_parts(
    int_val: u128,
    scale: i16,
    negative: bool
) -> Result<Decimal, DecimalConvertError>
[src]

Creates a Decimal from parts.

int_val has at most 38 tens digits, scale ranges from [-126, 130].

pub const fn into_parts(self) -> (u128, i16, bool)[src]

Consumes the Decimal, returning (int_val, scale, negative).

pub fn precision(&self) -> u8[src]

Returns the precision, i.e. the count of significant digits in this decimal.

pub const fn scale(&self) -> i16[src]

Returns the scale, i.e. the count of decimal digits in the fractional part. A positive scale means a negative power of 10.

pub const fn is_sign_negative(&self) -> bool[src]

Returns true if the sign bit of the decimal is negative.

pub const fn is_sign_positive(&self) -> bool[src]

Returns true if the sign bit of the decimal is positive.

pub const fn is_zero(&self) -> bool[src]

Checks if self is zero.

pub const fn abs(&self) -> Decimal[src]

Computes the absolute value of self.

pub fn encode<W: Write>(&self, writer: W) -> Result<usize>[src]

Encodes self to writer as binary bytes. Returns total size on success, which is not larger than MAX_BINARY_SIZE.

pub fn compact_encode<W: Write>(&self, writer: W) -> Result<usize>[src]

Encodes self to writer as binary bytes. Returns total size on success, which is not larger than MAX_BINARY_SIZE.

The only different from Decimal::encode is it will compact encoded bytes when self is zero or small positive integer.

pub fn decode(bytes: &[u8]) -> Decimal[src]

Decodes a Decimal from binary bytes.

pub fn trunc(&self, scale: i16) -> Decimal[src]

Truncate a value to have scale digits after the decimal point. We allow negative scale, implying a truncation before the decimal point.

pub fn round(&self, scale: i16) -> Decimal[src]

Round a value to have scale digits after the decimal point. We allow negative scale, implying rounding before the decimal point.

pub fn round_with_precision(&mut self, precision: u8, scale: i16) -> bool[src]

Do bounds checking and rounding according to precision and scale.

Returns true if overflows.

pub fn normalize(&self) -> Decimal[src]

Normalize a Decimal’s scale toward zero.

pub fn checked_add(&self, other: Decimal) -> Option<Decimal>[src]

Add two decimals, returning None if overflow occurred.

pub fn checked_sub(&self, other: Decimal) -> Option<Decimal>[src]

Subtract one decimal from another, returning None if overflow occurred.

pub fn checked_mul(&self, other: Decimal) -> Option<Decimal>[src]

Calculate the product of two decimals, returning None if overflow occurred.

pub fn checked_div(&self, other: Decimal) -> Option<Decimal>[src]

Checked decimal division. Computes self / other, returning None if other == 0 or the division results in overflow.

pub fn checked_rem(&self, other: Decimal) -> Option<Decimal>[src]

Checked decimal remainder. Computes self % other, returning None if rhs == 0 or the division results in overflow.

Trait Implementations

impl Add<&'_ Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: &Decimal) -> Self::Output[src]

Performs the + operation. Read more

impl Add<&'_ Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: &Decimal) -> Self::Output[src]

Performs the + operation. Read more

impl Add<Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: Decimal) -> Self::Output[src]

Performs the + operation. Read more

impl Add<Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: Self) -> Self::Output[src]

Performs the + operation. Read more

impl Add<f32> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: f32) -> Self::Output[src]

Performs the + operation. Read more

impl Add<f32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: f32) -> Self::Output[src]

Performs the + operation. Read more

impl Add<f64> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: f64) -> Self::Output[src]

Performs the + operation. Read more

impl Add<f64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: f64) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i128> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i128) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i128) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i16> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i16) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i16) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i32> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i32) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i32) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i64> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i64) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i64) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i8> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i8) -> Self::Output[src]

Performs the + operation. Read more

impl Add<i8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: i8) -> Self::Output[src]

Performs the + operation. Read more

impl Add<isize> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: isize) -> Self::Output[src]

Performs the + operation. Read more

impl Add<isize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: isize) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u128> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u128) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u128) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u16> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u16) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u16) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u32> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u32) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u32) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u64> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u64) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u64) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u8> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u8) -> Self::Output[src]

Performs the + operation. Read more

impl Add<u8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: u8) -> Self::Output[src]

Performs the + operation. Read more

impl Add<usize> for Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: usize) -> Self::Output[src]

Performs the + operation. Read more

impl Add<usize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the + operator.

fn add(self, other: usize) -> Self::Output[src]

Performs the + operation. Read more

impl AddAssign<&'_ Decimal> for Decimal[src]

fn add_assign(&mut self, other: &Decimal)[src]

Performs the += operation. Read more

impl AddAssign<&'_ Decimal> for &mut Decimal[src]

fn add_assign(&mut self, other: &Decimal)[src]

Performs the += operation. Read more

impl AddAssign<Decimal> for Decimal[src]

fn add_assign(&mut self, other: Decimal)[src]

Performs the += operation. Read more

impl AddAssign<Decimal> for &mut Decimal[src]

fn add_assign(&mut self, other: Decimal)[src]

Performs the += operation. Read more

impl AddAssign<f32> for Decimal[src]

fn add_assign(&mut self, other: f32)[src]

Performs the += operation. Read more

impl AddAssign<f32> for &mut Decimal[src]

fn add_assign(&mut self, other: f32)[src]

Performs the += operation. Read more

impl AddAssign<f64> for Decimal[src]

fn add_assign(&mut self, other: f64)[src]

Performs the += operation. Read more

impl AddAssign<f64> for &mut Decimal[src]

fn add_assign(&mut self, other: f64)[src]

Performs the += operation. Read more

impl AddAssign<i128> for Decimal[src]

fn add_assign(&mut self, other: i128)[src]

Performs the += operation. Read more

impl AddAssign<i128> for &mut Decimal[src]

fn add_assign(&mut self, other: i128)[src]

Performs the += operation. Read more

impl AddAssign<i16> for Decimal[src]

fn add_assign(&mut self, other: i16)[src]

Performs the += operation. Read more

impl AddAssign<i16> for &mut Decimal[src]

fn add_assign(&mut self, other: i16)[src]

Performs the += operation. Read more

impl AddAssign<i32> for Decimal[src]

fn add_assign(&mut self, other: i32)[src]

Performs the += operation. Read more

impl AddAssign<i32> for &mut Decimal[src]

fn add_assign(&mut self, other: i32)[src]

Performs the += operation. Read more

impl AddAssign<i64> for Decimal[src]

fn add_assign(&mut self, other: i64)[src]

Performs the += operation. Read more

impl AddAssign<i64> for &mut Decimal[src]

fn add_assign(&mut self, other: i64)[src]

Performs the += operation. Read more

impl AddAssign<i8> for Decimal[src]

fn add_assign(&mut self, other: i8)[src]

Performs the += operation. Read more

impl AddAssign<i8> for &mut Decimal[src]

fn add_assign(&mut self, other: i8)[src]

Performs the += operation. Read more

impl AddAssign<isize> for Decimal[src]

fn add_assign(&mut self, other: isize)[src]

Performs the += operation. Read more

impl AddAssign<isize> for &mut Decimal[src]

fn add_assign(&mut self, other: isize)[src]

Performs the += operation. Read more

impl AddAssign<u128> for Decimal[src]

fn add_assign(&mut self, other: u128)[src]

Performs the += operation. Read more

impl AddAssign<u128> for &mut Decimal[src]

fn add_assign(&mut self, other: u128)[src]

Performs the += operation. Read more

impl AddAssign<u16> for Decimal[src]

fn add_assign(&mut self, other: u16)[src]

Performs the += operation. Read more

impl AddAssign<u16> for &mut Decimal[src]

fn add_assign(&mut self, other: u16)[src]

Performs the += operation. Read more

impl AddAssign<u32> for Decimal[src]

fn add_assign(&mut self, other: u32)[src]

Performs the += operation. Read more

impl AddAssign<u32> for &mut Decimal[src]

fn add_assign(&mut self, other: u32)[src]

Performs the += operation. Read more

impl AddAssign<u64> for Decimal[src]

fn add_assign(&mut self, other: u64)[src]

Performs the += operation. Read more

impl AddAssign<u64> for &mut Decimal[src]

fn add_assign(&mut self, other: u64)[src]

Performs the += operation. Read more

impl AddAssign<u8> for Decimal[src]

fn add_assign(&mut self, other: u8)[src]

Performs the += operation. Read more

impl AddAssign<u8> for &mut Decimal[src]

fn add_assign(&mut self, other: u8)[src]

Performs the += operation. Read more

impl AddAssign<usize> for Decimal[src]

fn add_assign(&mut self, other: usize)[src]

Performs the += operation. Read more

impl AddAssign<usize> for &mut Decimal[src]

fn add_assign(&mut self, other: usize)[src]

Performs the += operation. Read more

impl Clone for Decimal[src]

fn clone(&self) -> Decimal[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for Decimal[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Default for Decimal[src]

fn default() -> Self[src]

Returns the “default value” for a type. Read more

impl Display for Decimal[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Div<&'_ Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: &Decimal) -> Self::Output[src]

Performs the / operation. Read more

impl Div<&'_ Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: &Decimal) -> Self::Output[src]

Performs the / operation. Read more

impl Div<Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: Decimal) -> Decimal[src]

Performs the / operation. Read more

impl Div<Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: Self) -> Self::Output[src]

Performs the / operation. Read more

impl Div<f32> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: f32) -> Self::Output[src]

Performs the / operation. Read more

impl Div<f32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: f32) -> Self::Output[src]

Performs the / operation. Read more

impl Div<f64> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: f64) -> Self::Output[src]

Performs the / operation. Read more

impl Div<f64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: f64) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i128> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i128) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i128) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i16> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i16) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i16) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i32> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i32) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i32) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i64> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i64) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i64) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i8> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i8) -> Self::Output[src]

Performs the / operation. Read more

impl Div<i8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: i8) -> Self::Output[src]

Performs the / operation. Read more

impl Div<isize> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: isize) -> Self::Output[src]

Performs the / operation. Read more

impl Div<isize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: isize) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u128> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u128) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u128) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u16> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u16) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u16) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u32> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u32) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u32) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u64> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u64) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u64) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u8> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u8) -> Self::Output[src]

Performs the / operation. Read more

impl Div<u8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: u8) -> Self::Output[src]

Performs the / operation. Read more

impl Div<usize> for Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: usize) -> Self::Output[src]

Performs the / operation. Read more

impl Div<usize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the / operator.

fn div(self, other: usize) -> Self::Output[src]

Performs the / operation. Read more

impl DivAssign<&'_ Decimal> for Decimal[src]

fn div_assign(&mut self, other: &Decimal)[src]

Performs the /= operation. Read more

impl DivAssign<&'_ Decimal> for &mut Decimal[src]

fn div_assign(&mut self, other: &Decimal)[src]

Performs the /= operation. Read more

impl DivAssign<Decimal> for Decimal[src]

fn div_assign(&mut self, other: Decimal)[src]

Performs the /= operation. Read more

impl DivAssign<Decimal> for &mut Decimal[src]

fn div_assign(&mut self, other: Decimal)[src]

Performs the /= operation. Read more

impl DivAssign<f32> for Decimal[src]

fn div_assign(&mut self, other: f32)[src]

Performs the /= operation. Read more

impl DivAssign<f32> for &mut Decimal[src]

fn div_assign(&mut self, other: f32)[src]

Performs the /= operation. Read more

impl DivAssign<f64> for Decimal[src]

fn div_assign(&mut self, other: f64)[src]

Performs the /= operation. Read more

impl DivAssign<f64> for &mut Decimal[src]

fn div_assign(&mut self, other: f64)[src]

Performs the /= operation. Read more

impl DivAssign<i128> for Decimal[src]

fn div_assign(&mut self, other: i128)[src]

Performs the /= operation. Read more

impl DivAssign<i128> for &mut Decimal[src]

fn div_assign(&mut self, other: i128)[src]

Performs the /= operation. Read more

impl DivAssign<i16> for Decimal[src]

fn div_assign(&mut self, other: i16)[src]

Performs the /= operation. Read more

impl DivAssign<i16> for &mut Decimal[src]

fn div_assign(&mut self, other: i16)[src]

Performs the /= operation. Read more

impl DivAssign<i32> for Decimal[src]

fn div_assign(&mut self, other: i32)[src]

Performs the /= operation. Read more

impl DivAssign<i32> for &mut Decimal[src]

fn div_assign(&mut self, other: i32)[src]

Performs the /= operation. Read more

impl DivAssign<i64> for Decimal[src]

fn div_assign(&mut self, other: i64)[src]

Performs the /= operation. Read more

impl DivAssign<i64> for &mut Decimal[src]

fn div_assign(&mut self, other: i64)[src]

Performs the /= operation. Read more

impl DivAssign<i8> for Decimal[src]

fn div_assign(&mut self, other: i8)[src]

Performs the /= operation. Read more

impl DivAssign<i8> for &mut Decimal[src]

fn div_assign(&mut self, other: i8)[src]

Performs the /= operation. Read more

impl DivAssign<isize> for Decimal[src]

fn div_assign(&mut self, other: isize)[src]

Performs the /= operation. Read more

impl DivAssign<isize> for &mut Decimal[src]

fn div_assign(&mut self, other: isize)[src]

Performs the /= operation. Read more

impl DivAssign<u128> for Decimal[src]

fn div_assign(&mut self, other: u128)[src]

Performs the /= operation. Read more

impl DivAssign<u128> for &mut Decimal[src]

fn div_assign(&mut self, other: u128)[src]

Performs the /= operation. Read more

impl DivAssign<u16> for Decimal[src]

fn div_assign(&mut self, other: u16)[src]

Performs the /= operation. Read more

impl DivAssign<u16> for &mut Decimal[src]

fn div_assign(&mut self, other: u16)[src]

Performs the /= operation. Read more

impl DivAssign<u32> for Decimal[src]

fn div_assign(&mut self, other: u32)[src]

Performs the /= operation. Read more

impl DivAssign<u32> for &mut Decimal[src]

fn div_assign(&mut self, other: u32)[src]

Performs the /= operation. Read more

impl DivAssign<u64> for Decimal[src]

fn div_assign(&mut self, other: u64)[src]

Performs the /= operation. Read more

impl DivAssign<u64> for &mut Decimal[src]

fn div_assign(&mut self, other: u64)[src]

Performs the /= operation. Read more

impl DivAssign<u8> for Decimal[src]

fn div_assign(&mut self, other: u8)[src]

Performs the /= operation. Read more

impl DivAssign<u8> for &mut Decimal[src]

fn div_assign(&mut self, other: u8)[src]

Performs the /= operation. Read more

impl DivAssign<usize> for Decimal[src]

fn div_assign(&mut self, other: usize)[src]

Performs the /= operation. Read more

impl DivAssign<usize> for &mut Decimal[src]

fn div_assign(&mut self, other: usize)[src]

Performs the /= operation. Read more

impl From<bool> for Decimal[src]

fn from(b: bool) -> Self[src]

Performs the conversion.

impl From<i16> for Decimal[src]

fn from(val: i16) -> Decimal[src]

Performs the conversion.

impl From<i32> for Decimal[src]

fn from(val: i32) -> Decimal[src]

Performs the conversion.

impl From<i64> for Decimal[src]

fn from(val: i64) -> Decimal[src]

Performs the conversion.

impl From<i8> for Decimal[src]

fn from(val: i8) -> Decimal[src]

Performs the conversion.

impl From<isize> for Decimal[src]

fn from(val: isize) -> Decimal[src]

Performs the conversion.

impl From<u16> for Decimal[src]

fn from(val: u16) -> Self[src]

Performs the conversion.

impl From<u32> for Decimal[src]

fn from(val: u32) -> Self[src]

Performs the conversion.

impl From<u64> for Decimal[src]

fn from(val: u64) -> Self[src]

Performs the conversion.

impl From<u8> for Decimal[src]

fn from(val: u8) -> Self[src]

Performs the conversion.

impl From<usize> for Decimal[src]

fn from(val: usize) -> Self[src]

Performs the conversion.

impl FromStr for Decimal[src]

type Err = DecimalParseError

The associated error which can be returned from parsing.

fn from_str(s: &str) -> Result<Self, Self::Err>[src]

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

impl Hash for Decimal[src]

fn hash<H: Hasher>(&self, state: &mut H)[src]

Feeds this value into the given Hasher. Read more

fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher
1.3.0[src]

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

impl Mul<&'_ Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: &Decimal) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<&'_ Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: &Decimal) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: Decimal) -> Decimal[src]

Performs the * operation. Read more

impl Mul<Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: Self) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<f32> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: f32) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<f32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: f32) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<f64> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: f64) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<f64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: f64) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i128> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i128) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i128) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i16> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i16) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i16) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i32> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i32) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i32) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i64> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i64) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i64) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i8> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i8) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<i8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: i8) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<isize> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: isize) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<isize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: isize) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u128> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u128) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u128) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u16> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u16) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u16) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u32> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u32) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u32) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u64> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u64) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u64) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u8> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u8) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<u8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: u8) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<usize> for Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: usize) -> Self::Output[src]

Performs the * operation. Read more

impl Mul<usize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the * operator.

fn mul(self, other: usize) -> Self::Output[src]

Performs the * operation. Read more

impl MulAssign<&'_ Decimal> for Decimal[src]

fn mul_assign(&mut self, other: &Decimal)[src]

Performs the *= operation. Read more

impl MulAssign<&'_ Decimal> for &mut Decimal[src]

fn mul_assign(&mut self, other: &Decimal)[src]

Performs the *= operation. Read more

impl MulAssign<Decimal> for Decimal[src]

fn mul_assign(&mut self, other: Decimal)[src]

Performs the *= operation. Read more

impl MulAssign<Decimal> for &mut Decimal[src]

fn mul_assign(&mut self, other: Decimal)[src]

Performs the *= operation. Read more

impl MulAssign<f32> for Decimal[src]

fn mul_assign(&mut self, other: f32)[src]

Performs the *= operation. Read more

impl MulAssign<f32> for &mut Decimal[src]

fn mul_assign(&mut self, other: f32)[src]

Performs the *= operation. Read more

impl MulAssign<f64> for Decimal[src]

fn mul_assign(&mut self, other: f64)[src]

Performs the *= operation. Read more

impl MulAssign<f64> for &mut Decimal[src]

fn mul_assign(&mut self, other: f64)[src]

Performs the *= operation. Read more

impl MulAssign<i128> for Decimal[src]

fn mul_assign(&mut self, other: i128)[src]

Performs the *= operation. Read more

impl MulAssign<i128> for &mut Decimal[src]

fn mul_assign(&mut self, other: i128)[src]

Performs the *= operation. Read more

impl MulAssign<i16> for Decimal[src]

fn mul_assign(&mut self, other: i16)[src]

Performs the *= operation. Read more

impl MulAssign<i16> for &mut Decimal[src]

fn mul_assign(&mut self, other: i16)[src]

Performs the *= operation. Read more

impl MulAssign<i32> for Decimal[src]

fn mul_assign(&mut self, other: i32)[src]

Performs the *= operation. Read more

impl MulAssign<i32> for &mut Decimal[src]

fn mul_assign(&mut self, other: i32)[src]

Performs the *= operation. Read more

impl MulAssign<i64> for Decimal[src]

fn mul_assign(&mut self, other: i64)[src]

Performs the *= operation. Read more

impl MulAssign<i64> for &mut Decimal[src]

fn mul_assign(&mut self, other: i64)[src]

Performs the *= operation. Read more

impl MulAssign<i8> for Decimal[src]

fn mul_assign(&mut self, other: i8)[src]

Performs the *= operation. Read more

impl MulAssign<i8> for &mut Decimal[src]

fn mul_assign(&mut self, other: i8)[src]

Performs the *= operation. Read more

impl MulAssign<isize> for Decimal[src]

fn mul_assign(&mut self, other: isize)[src]

Performs the *= operation. Read more

impl MulAssign<isize> for &mut Decimal[src]

fn mul_assign(&mut self, other: isize)[src]

Performs the *= operation. Read more

impl MulAssign<u128> for Decimal[src]

fn mul_assign(&mut self, other: u128)[src]

Performs the *= operation. Read more

impl MulAssign<u128> for &mut Decimal[src]

fn mul_assign(&mut self, other: u128)[src]

Performs the *= operation. Read more

impl MulAssign<u16> for Decimal[src]

fn mul_assign(&mut self, other: u16)[src]

Performs the *= operation. Read more

impl MulAssign<u16> for &mut Decimal[src]

fn mul_assign(&mut self, other: u16)[src]

Performs the *= operation. Read more

impl MulAssign<u32> for Decimal[src]

fn mul_assign(&mut self, other: u32)[src]

Performs the *= operation. Read more

impl MulAssign<u32> for &mut Decimal[src]

fn mul_assign(&mut self, other: u32)[src]

Performs the *= operation. Read more

impl MulAssign<u64> for Decimal[src]

fn mul_assign(&mut self, other: u64)[src]

Performs the *= operation. Read more

impl MulAssign<u64> for &mut Decimal[src]

fn mul_assign(&mut self, other: u64)[src]

Performs the *= operation. Read more

impl MulAssign<u8> for Decimal[src]

fn mul_assign(&mut self, other: u8)[src]

Performs the *= operation. Read more

impl MulAssign<u8> for &mut Decimal[src]

fn mul_assign(&mut self, other: u8)[src]

Performs the *= operation. Read more

impl MulAssign<usize> for Decimal[src]

fn mul_assign(&mut self, other: usize)[src]

Performs the *= operation. Read more

impl MulAssign<usize> for &mut Decimal[src]

fn mul_assign(&mut self, other: usize)[src]

Performs the *= operation. Read more

impl Neg for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn neg(self) -> Self::Output[src]

Performs the unary - operation. Read more

impl Neg for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn neg(self) -> Self::Output[src]

Performs the unary - operation. Read more

impl Ord for Decimal[src]

fn cmp(&self, other: &Self) -> Ordering[src]

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

#[must_use]
fn max(self, other: Self) -> Self
1.21.0[src]

Compares and returns the maximum of two values. Read more

#[must_use]
fn min(self, other: Self) -> Self
1.21.0[src]

Compares and returns the minimum of two values. Read more

#[must_use]
fn clamp(self, min: Self, max: Self) -> Self
1.50.0[src]

Restrict a value to a certain interval. Read more

impl PartialEq<&'_ Decimal> for Decimal[src]

fn eq(&self, other: &&Decimal) -> bool[src]

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

#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests for !=.

impl PartialEq<Decimal> for Decimal[src]

fn eq(&self, other: &Self) -> bool[src]

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

#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests for !=.

impl PartialEq<Decimal> for &Decimal[src]

fn eq(&self, other: &Decimal) -> bool[src]

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

#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests for !=.

impl PartialOrd<&'_ Decimal> for Decimal[src]

fn partial_cmp(&self, other: &&Decimal) -> 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]

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]

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

#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]

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

#[must_use]
fn ge(&self, other: &Rhs) -> bool
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 PartialOrd<Decimal> for Decimal[src]

fn partial_cmp(&self, other: &Self) -> 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]

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]

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

#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]

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

#[must_use]
fn ge(&self, other: &Rhs) -> bool
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 PartialOrd<Decimal> for &Decimal[src]

fn partial_cmp(&self, other: &Decimal) -> 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]

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]

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

#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]

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

#[must_use]
fn ge(&self, other: &Rhs) -> bool
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 Rem<&'_ Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: &Decimal) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<&'_ Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: &Decimal) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: Decimal) -> Decimal[src]

Performs the % operation. Read more

impl Rem<Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: Self) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<f32> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: f32) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<f32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: f32) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<f64> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: f64) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<f64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: f64) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i128> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i128) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i128) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i16> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i16) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i16) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i32> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i32) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i32) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i64> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i64) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i64) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i8> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i8) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<i8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: i8) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<isize> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: isize) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<isize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: isize) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u128> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u128) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u128) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u16> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u16) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u16) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u32> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u32) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u32) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u64> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u64) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u64) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u8> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u8) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<u8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: u8) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<usize> for Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: usize) -> Self::Output[src]

Performs the % operation. Read more

impl Rem<usize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the % operator.

fn rem(self, other: usize) -> Self::Output[src]

Performs the % operation. Read more

impl RemAssign<&'_ Decimal> for Decimal[src]

fn rem_assign(&mut self, other: &Decimal)[src]

Performs the %= operation. Read more

impl RemAssign<&'_ Decimal> for &mut Decimal[src]

fn rem_assign(&mut self, other: &Decimal)[src]

Performs the %= operation. Read more

impl RemAssign<Decimal> for Decimal[src]

fn rem_assign(&mut self, other: Decimal)[src]

Performs the %= operation. Read more

impl RemAssign<Decimal> for &mut Decimal[src]

fn rem_assign(&mut self, other: Decimal)[src]

Performs the %= operation. Read more

impl RemAssign<f32> for Decimal[src]

fn rem_assign(&mut self, other: f32)[src]

Performs the %= operation. Read more

impl RemAssign<f32> for &mut Decimal[src]

fn rem_assign(&mut self, other: f32)[src]

Performs the %= operation. Read more

impl RemAssign<f64> for Decimal[src]

fn rem_assign(&mut self, other: f64)[src]

Performs the %= operation. Read more

impl RemAssign<f64> for &mut Decimal[src]

fn rem_assign(&mut self, other: f64)[src]

Performs the %= operation. Read more

impl RemAssign<i128> for Decimal[src]

fn rem_assign(&mut self, other: i128)[src]

Performs the %= operation. Read more

impl RemAssign<i128> for &mut Decimal[src]

fn rem_assign(&mut self, other: i128)[src]

Performs the %= operation. Read more

impl RemAssign<i16> for Decimal[src]

fn rem_assign(&mut self, other: i16)[src]

Performs the %= operation. Read more

impl RemAssign<i16> for &mut Decimal[src]

fn rem_assign(&mut self, other: i16)[src]

Performs the %= operation. Read more

impl RemAssign<i32> for Decimal[src]

fn rem_assign(&mut self, other: i32)[src]

Performs the %= operation. Read more

impl RemAssign<i32> for &mut Decimal[src]

fn rem_assign(&mut self, other: i32)[src]

Performs the %= operation. Read more

impl RemAssign<i64> for Decimal[src]

fn rem_assign(&mut self, other: i64)[src]

Performs the %= operation. Read more

impl RemAssign<i64> for &mut Decimal[src]

fn rem_assign(&mut self, other: i64)[src]

Performs the %= operation. Read more

impl RemAssign<i8> for Decimal[src]

fn rem_assign(&mut self, other: i8)[src]

Performs the %= operation. Read more

impl RemAssign<i8> for &mut Decimal[src]

fn rem_assign(&mut self, other: i8)[src]

Performs the %= operation. Read more

impl RemAssign<isize> for Decimal[src]

fn rem_assign(&mut self, other: isize)[src]

Performs the %= operation. Read more

impl RemAssign<isize> for &mut Decimal[src]

fn rem_assign(&mut self, other: isize)[src]

Performs the %= operation. Read more

impl RemAssign<u128> for Decimal[src]

fn rem_assign(&mut self, other: u128)[src]

Performs the %= operation. Read more

impl RemAssign<u128> for &mut Decimal[src]

fn rem_assign(&mut self, other: u128)[src]

Performs the %= operation. Read more

impl RemAssign<u16> for Decimal[src]

fn rem_assign(&mut self, other: u16)[src]

Performs the %= operation. Read more

impl RemAssign<u16> for &mut Decimal[src]

fn rem_assign(&mut self, other: u16)[src]

Performs the %= operation. Read more

impl RemAssign<u32> for Decimal[src]

fn rem_assign(&mut self, other: u32)[src]

Performs the %= operation. Read more

impl RemAssign<u32> for &mut Decimal[src]

fn rem_assign(&mut self, other: u32)[src]

Performs the %= operation. Read more

impl RemAssign<u64> for Decimal[src]

fn rem_assign(&mut self, other: u64)[src]

Performs the %= operation. Read more

impl RemAssign<u64> for &mut Decimal[src]

fn rem_assign(&mut self, other: u64)[src]

Performs the %= operation. Read more

impl RemAssign<u8> for Decimal[src]

fn rem_assign(&mut self, other: u8)[src]

Performs the %= operation. Read more

impl RemAssign<u8> for &mut Decimal[src]

fn rem_assign(&mut self, other: u8)[src]

Performs the %= operation. Read more

impl RemAssign<usize> for Decimal[src]

fn rem_assign(&mut self, other: usize)[src]

Performs the %= operation. Read more

impl RemAssign<usize> for &mut Decimal[src]

fn rem_assign(&mut self, other: usize)[src]

Performs the %= operation. Read more

impl Sub<&'_ Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: &Decimal) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<&'_ Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: &Decimal) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<Decimal> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: Decimal) -> Decimal[src]

Performs the - operation. Read more

impl Sub<Decimal> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: Self) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<f32> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: f32) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<f32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: f32) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<f64> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: f64) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<f64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: f64) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i128> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i128) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i128) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i16> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i16) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i16) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i32> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i32) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i32) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i64> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i64) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i64) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i8> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i8) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<i8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: i8) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<isize> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: isize) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<isize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: isize) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u128> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u128) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u128> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u128) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u16> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u16) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u16> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u16) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u32> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u32) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u32> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u32) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u64> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u64) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u64> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u64) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u8> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u8) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<u8> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: u8) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<usize> for Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: usize) -> Self::Output[src]

Performs the - operation. Read more

impl Sub<usize> for &Decimal[src]

type Output = Decimal

The resulting type after applying the - operator.

fn sub(self, other: usize) -> Self::Output[src]

Performs the - operation. Read more

impl SubAssign<&'_ Decimal> for Decimal[src]

fn sub_assign(&mut self, other: &Decimal)[src]

Performs the -= operation. Read more

impl SubAssign<&'_ Decimal> for &mut Decimal[src]

fn sub_assign(&mut self, other: &Decimal)[src]

Performs the -= operation. Read more

impl SubAssign<Decimal> for Decimal[src]

fn sub_assign(&mut self, other: Decimal)[src]

Performs the -= operation. Read more

impl SubAssign<Decimal> for &mut Decimal[src]

fn sub_assign(&mut self, other: Decimal)[src]

Performs the -= operation. Read more

impl SubAssign<f32> for Decimal[src]

fn sub_assign(&mut self, other: f32)[src]

Performs the -= operation. Read more

impl SubAssign<f32> for &mut Decimal[src]

fn sub_assign(&mut self, other: f32)[src]

Performs the -= operation. Read more

impl SubAssign<f64> for Decimal[src]

fn sub_assign(&mut self, other: f64)[src]

Performs the -= operation. Read more

impl SubAssign<f64> for &mut Decimal[src]

fn sub_assign(&mut self, other: f64)[src]

Performs the -= operation. Read more

impl SubAssign<i128> for Decimal[src]

fn sub_assign(&mut self, other: i128)[src]

Performs the -= operation. Read more

impl SubAssign<i128> for &mut Decimal[src]

fn sub_assign(&mut self, other: i128)[src]

Performs the -= operation. Read more

impl SubAssign<i16> for Decimal[src]

fn sub_assign(&mut self, other: i16)[src]

Performs the -= operation. Read more

impl SubAssign<i16> for &mut Decimal[src]

fn sub_assign(&mut self, other: i16)[src]

Performs the -= operation. Read more

impl SubAssign<i32> for Decimal[src]

fn sub_assign(&mut self, other: i32)[src]

Performs the -= operation. Read more

impl SubAssign<i32> for &mut Decimal[src]

fn sub_assign(&mut self, other: i32)[src]

Performs the -= operation. Read more

impl SubAssign<i64> for Decimal[src]

fn sub_assign(&mut self, other: i64)[src]

Performs the -= operation. Read more

impl SubAssign<i64> for &mut Decimal[src]

fn sub_assign(&mut self, other: i64)[src]

Performs the -= operation. Read more

impl SubAssign<i8> for Decimal[src]

fn sub_assign(&mut self, other: i8)[src]

Performs the -= operation. Read more

impl SubAssign<i8> for &mut Decimal[src]

fn sub_assign(&mut self, other: i8)[src]

Performs the -= operation. Read more

impl SubAssign<isize> for Decimal[src]

fn sub_assign(&mut self, other: isize)[src]

Performs the -= operation. Read more

impl SubAssign<isize> for &mut Decimal[src]

fn sub_assign(&mut self, other: isize)[src]

Performs the -= operation. Read more

impl SubAssign<u128> for Decimal[src]

fn sub_assign(&mut self, other: u128)[src]

Performs the -= operation. Read more

impl SubAssign<u128> for &mut Decimal[src]

fn sub_assign(&mut self, other: u128)[src]

Performs the -= operation. Read more

impl SubAssign<u16> for Decimal[src]

fn sub_assign(&mut self, other: u16)[src]

Performs the -= operation. Read more

impl SubAssign<u16> for &mut Decimal[src]

fn sub_assign(&mut self, other: u16)[src]

Performs the -= operation. Read more

impl SubAssign<u32> for Decimal[src]

fn sub_assign(&mut self, other: u32)[src]

Performs the -= operation. Read more

impl SubAssign<u32> for &mut Decimal[src]

fn sub_assign(&mut self, other: u32)[src]

Performs the -= operation. Read more

impl SubAssign<u64> for Decimal[src]

fn sub_assign(&mut self, other: u64)[src]

Performs the -= operation. Read more

impl SubAssign<u64> for &mut Decimal[src]

fn sub_assign(&mut self, other: u64)[src]

Performs the -= operation. Read more

impl SubAssign<u8> for Decimal[src]

fn sub_assign(&mut self, other: u8)[src]

Performs the -= operation. Read more

impl SubAssign<u8> for &mut Decimal[src]

fn sub_assign(&mut self, other: u8)[src]

Performs the -= operation. Read more

impl SubAssign<usize> for Decimal[src]

fn sub_assign(&mut self, other: usize)[src]

Performs the -= operation. Read more

impl SubAssign<usize> for &mut Decimal[src]

fn sub_assign(&mut self, other: usize)[src]

Performs the -= operation. Read more

impl TryFrom<f32> for Decimal[src]

type Error = DecimalConvertError

The type returned in the event of a conversion error.

fn try_from(value: f32) -> Result<Self, Self::Error>[src]

Performs the conversion.

impl TryFrom<f64> for Decimal[src]

type Error = DecimalConvertError

The type returned in the event of a conversion error.

fn try_from(value: f64) -> Result<Self, Self::Error>[src]

Performs the conversion.

impl TryFrom<i128> for Decimal[src]

type Error = DecimalConvertError

The type returned in the event of a conversion error.

fn try_from(val: i128) -> Result<Self, Self::Error>[src]

Performs the conversion.

impl TryFrom<u128> for Decimal[src]

type Error = DecimalConvertError

The type returned in the event of a conversion error.

fn try_from(value: u128) -> Result<Self, Self::Error>[src]

Performs the conversion.

impl Copy for Decimal[src]

impl Eq for Decimal[src]

impl StructuralEq for Decimal[src]

Auto Trait Implementations

impl RefUnwindSafe for Decimal

impl Send for Decimal

impl Sync for Decimal

impl Unpin for Decimal

impl UnwindSafe for Decimal

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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]

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

impl<T> ToString for T where
    T: Display + ?Sized
[src]

pub default fn to_string(&self) -> String[src]

Converts the given value to a String. Read more

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.