Crate currencies_core

Crate currencies_core 

Source
Expand description

Core functionality for currencies crate, not including proc macros.

Re-exports§

pub use amount::Amount;
pub use amount::Backing;
pub use currency::Currency;
pub use u256::U256;

Modules§

amount
Home of the Amount struct and supporting types and impls.
currency
Home of the Currency trait, all built-in currencies such as USD, AAVE, ETH, etc., the define_currency! macro, and related/supporting types.
safety
Home of the Safety sealed type and its two variants Checked and Unchecked.
u256
Home of the U256 type, which is a heavily modified, wrapped version of primitive_types::U256 with several custom impls and additional traits from num_traits that are necessary for currency manipulation but not included by default.

Macros§

define_currency
Shorthand for defining a new Currency. All ISO-4217 currencies already have an entry.