Struct monies::LocalFormat[][src]

pub struct LocalFormat {
    pub name: &'static str,
    pub digit_separator: char,
    pub digit_separator_pattern: &'static str,
    pub exponent_separator: char,
}

Stores currency formatting metadata for a specific region (e.g. EN-US).

Fields

name: &'static strdigit_separator: chardigit_separator_pattern: &'static strexponent_separator: char

Implementations

impl LocalFormat[src]

pub fn digit_separator_pattern(&self) -> Vec<usize>[src]

Returns a vector indicating where digit separators should be applied on a Money amount.

For example, [3,3,3] indicates that the digit separator should be applied after the 3rd, 6th and 9th digits.

pub fn from_locale(locale: Locale) -> LocalFormat[src]

Returns the associated LocalFormat given a Locale.

Trait Implementations

impl Debug for LocalFormat[src]

impl Eq for LocalFormat[src]

impl PartialEq<LocalFormat> for LocalFormat[src]

impl StructuralEq for LocalFormat[src]

impl StructuralPartialEq for LocalFormat[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, 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.