Struct rgb20::AccountingAmount[][src]

pub struct AccountingAmount(_, _);

Accounting amount keeps track of the asset precision

Implementations

impl AccountingAmount[src]

pub fn transmutate_from(
    decimal_precision: u8,
    accounting_value: AccountingValue
) -> AtomicValue
[src]

pub fn transmutate_into(
    decimal_precision: u8,
    atomic_value: AtomicValue
) -> AccountingValue
[src]

pub fn from_asset_accounting_value(
    asset: &Asset,
    accounting_value: AccountingValue
) -> Self
[src]

pub fn from_fractioned_atomic_value(
    decimal_precision: u8,
    atomic_value: AtomicValue
) -> Self
[src]

pub fn from_fractioned_accounting_value(
    decimal_precision: u8,
    accounting_value: AccountingValue
) -> Self
[src]

pub fn from_asset_atomic_value(asset: &Asset, atomic_value: AtomicValue) -> Self[src]

pub fn accounting_value(&self) -> AccountingValue[src]

pub fn atomic_value(&self) -> AtomicValue[src]

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

Trait Implementations

impl Add<AccountingAmount> for AccountingAmount[src]

type Output = AccountingAmount

The resulting type after applying the + operator.

impl AddAssign<AccountingAmount> for AccountingAmount[src]

impl Clone for AccountingAmount[src]

impl Copy for AccountingAmount[src]

impl Debug for AccountingAmount[src]

impl Default for AccountingAmount[src]

impl Display for AccountingAmount[src]

impl Eq for AccountingAmount[src]

impl Hash for AccountingAmount[src]

impl PartialEq<AccountingAmount> for AccountingAmount[src]

impl StrictDecode for AccountingAmount[src]

impl StrictEncode for AccountingAmount[src]

impl StructuralEq for AccountingAmount[src]

impl StructuralPartialEq for AccountingAmount[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

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

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

impl<T> Same<T> for T

type Output = T

Should always be Self

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

type Owned = T

The resulting type after obtaining ownership.

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

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.

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,