pub enum Lang {
    English,
}
Expand description

Languages available in num2words

Variants

English

use num2words::{Num2Words, Lang};
assert_eq!(
    Num2Words::new(42).lang(Lang::English).to_words(),
    Ok(String::from("forty-two"))
);

Trait Implementations

Parses a string to return a value of this type

&strLang42
enLang::Englishforty-two

The associated error which can be returned from parsing.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.