Enum MinorCurrency
#[non_exhaustive]pub enum MinorCurrency {
Gbx,
Zax,
Ilx,
}Expand description
A minor-unit quote currency: a vendor code quoting prices in a fraction of
a major Currency (pence, cents, agorot).
Codes are case-sensitive: the market form carries a lowercase final letter
(GBp, ZAc, ILa), with all-uppercase vendor aliases (GBX, ZAX,
ILX, ILA) accepted for feeds that normalise case. ZAC is deliberately
not a minor-unit alias: it is ISO-shaped, so treating it as ZAR cents
would shadow a legitimate opaque Currency code; vendor feeds use ZAc
or ZAX for rand cents. Parsing a minor-unit code never alters what
Currency::new accepts.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Gbx
Pence sterling (GBp / GBX): 100 per GBP.
Zax
South African cents (ZAc / ZAX): 100 per ZAR.
Ilx
Israeli agorot (ILa / ILA / ILX): 100 per ILS.
Implementations§
§impl MinorCurrency
impl MinorCurrency
§impl MinorCurrency
impl MinorCurrency
Trait Implementations§
§impl Clone for MinorCurrency
impl Clone for MinorCurrency
§fn clone(&self) -> MinorCurrency
fn clone(&self) -> MinorCurrency
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for MinorCurrency
§impl Debug for MinorCurrency
impl Debug for MinorCurrency
impl Eq for MinorCurrency
§impl FromStr for MinorCurrency
impl FromStr for MinorCurrency
§impl Hash for MinorCurrency
impl Hash for MinorCurrency
§impl PartialEq for MinorCurrency
impl PartialEq for MinorCurrency
impl StructuralPartialEq for MinorCurrency
Auto Trait Implementations§
impl Freeze for MinorCurrency
impl RefUnwindSafe for MinorCurrency
impl Send for MinorCurrency
impl Sync for MinorCurrency
impl Unpin for MinorCurrency
impl UnsafeUnpin for MinorCurrency
impl UnwindSafe for MinorCurrency
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more