Enum CurrencyCode

Source
pub enum CurrencyCode {
Show 179 variants AED = 784, AFN = 971, ALL = 8, AMD = 51, ANG = 532, AOA = 973, ARS = 32, AUD = 36, AWG = 533, AZN = 944, BAM = 977, BBD = 52, BDT = 50, BGN = 975, BHD = 48, BIF = 108, BMD = 60, BND = 96, BOB = 68, BOV = 984, BRL = 986, BSD = 44, BTN = 64, BWP = 72, BYN = 933, BZD = 84, CAD = 124, CDF = 976, CHE = 947, CHF = 756, CHW = 948, CLF = 990, CLP = 152, CNY = 156, COP = 170, COU = 970, CRC = 188, CUC = 931, CUP = 192, CVE = 132, CZK = 203, DJF = 262, DKK = 208, DOP = 214, DZD = 12, EGP = 818, ERN = 232, ETB = 230, EUR = 978, FJD = 242, FKP = 238, GBP = 826, GEL = 981, GHS = 936, GIP = 292, GMD = 270, GNF = 324, GTQ = 320, GYD = 328, HKD = 344, HNL = 340, HRK = 191, HTG = 332, HUF = 348, IDR = 360, ILS = 376, INR = 356, IQD = 368, IRR = 364, ISK = 352, JMD = 388, JOD = 400, JPY = 392, KES = 404, KGS = 417, KHR = 116, KMF = 174, KPW = 408, KRW = 410, KWD = 414, KYD = 136, KZT = 398, LAK = 418, LBP = 422, LKR = 144, LRD = 430, LSL = 426, LYD = 434, MAD = 504, MDL = 498, MGA = 969, MKD = 807, MMK = 104, MNT = 496, MOP = 446, MRU = 929, MUR = 480, MVR = 462, MWK = 454, MXN = 484, MXV = 979, MYR = 458, MZN = 943, NAD = 516, NGN = 566, NIO = 558, NOK = 578, NPR = 524, NZD = 554, OMR = 512, PAB = 590, PEN = 604, PGK = 598, PHP = 608, PKR = 586, PLN = 985, PYG = 600, QAR = 634, RON = 946, RSD = 941, RUB = 643, RWF = 646, SAR = 682, SBD = 90, SCR = 690, SDG = 938, SEK = 752, SGD = 702, SHP = 654, SLL = 694, SOS = 706, SRD = 968, SSP = 728, STN = 930, SVC = 222, SYP = 760, SZL = 748, THB = 764, TJS = 972, TMT = 934, TND = 788, TOP = 776, TRY = 949, TTD = 780, TWD = 901, TZS = 834, UAH = 980, UGX = 800, USD = 840, USN = 997, UYI = 940, UYU = 858, UYW = 927, UZS = 860, VES = 928, VND = 704, VUV = 548, WST = 882, XAF = 950, XAG = 961, XAU = 959, XBA = 955, XBB = 956, XBC = 957, XBD = 958, XCD = 951, XDR = 960, XOF = 952, XPD = 964, XPF = 953, XPT = 962, XSU = 994, XTS = 963, XUA = 965, XXX = 999, YER = 886, ZAR = 710, ZMW = 967, ZWL = 932,
}
Expand description

CurrencyCode represents ISO-4217 currency code enumeration.

Variants§

§

AED = 784

§

AFN = 971

§

ALL = 8

§

AMD = 51

§

ANG = 532

§

AOA = 973

§

ARS = 32

§

AUD = 36

§

AWG = 533

§

AZN = 944

§

BAM = 977

§

BBD = 52

§

BDT = 50

§

BGN = 975

§

BHD = 48

§

BIF = 108

§

BMD = 60

§

BND = 96

§

BOB = 68

§

BOV = 984

§

BRL = 986

§

BSD = 44

§

BTN = 64

§

BWP = 72

§

BYN = 933

§

BZD = 84

§

CAD = 124

§

CDF = 976

§

CHE = 947

§

CHF = 756

§

CHW = 948

§

CLF = 990

§

CLP = 152

§

CNY = 156

§

COP = 170

§

COU = 970

§

CRC = 188

§

CUC = 931

§

CUP = 192

§

CVE = 132

§

CZK = 203

§

DJF = 262

§

DKK = 208

§

DOP = 214

§

DZD = 12

§

EGP = 818

§

ERN = 232

§

ETB = 230

§

EUR = 978

§

FJD = 242

§

FKP = 238

§

GBP = 826

§

GEL = 981

§

GHS = 936

§

GIP = 292

§

GMD = 270

§

GNF = 324

§

GTQ = 320

§

GYD = 328

§

HKD = 344

§

HNL = 340

§

HRK = 191

§

HTG = 332

§

HUF = 348

§

IDR = 360

§

ILS = 376

§

INR = 356

§

IQD = 368

§

IRR = 364

§

ISK = 352

§

JMD = 388

§

JOD = 400

§

JPY = 392

§

KES = 404

§

KGS = 417

§

KHR = 116

§

KMF = 174

§

KPW = 408

§

KRW = 410

§

KWD = 414

§

KYD = 136

§

KZT = 398

§

LAK = 418

§

LBP = 422

§

LKR = 144

§

LRD = 430

§

LSL = 426

§

LYD = 434

§

MAD = 504

§

MDL = 498

§

MGA = 969

§

MKD = 807

§

MMK = 104

§

MNT = 496

§

MOP = 446

§

MRU = 929

§

MUR = 480

§

MVR = 462

§

MWK = 454

§

MXN = 484

§

MXV = 979

§

MYR = 458

§

MZN = 943

§

NAD = 516

§

NGN = 566

§

NIO = 558

§

NOK = 578

§

NPR = 524

§

NZD = 554

§

OMR = 512

§

PAB = 590

§

PEN = 604

§

PGK = 598

§

PHP = 608

§

PKR = 586

§

PLN = 985

§

PYG = 600

§

QAR = 634

§

RON = 946

§

RSD = 941

§

RUB = 643

§

RWF = 646

§

SAR = 682

§

SBD = 90

§

SCR = 690

§

SDG = 938

§

SEK = 752

§

SGD = 702

§

SHP = 654

§

SLL = 694

§

SOS = 706

§

SRD = 968

§

SSP = 728

§

STN = 930

§

SVC = 222

§

SYP = 760

§

SZL = 748

§

THB = 764

§

TJS = 972

§

TMT = 934

§

TND = 788

§

TOP = 776

§

TRY = 949

§

TTD = 780

§

TWD = 901

§

TZS = 834

§

UAH = 980

§

UGX = 800

§

USD = 840

§

USN = 997

§

UYI = 940

§

UYU = 858

§

UYW = 927

§

UZS = 860

§

VES = 928

§

VND = 704

§

VUV = 548

§

WST = 882

§

XAF = 950

§

XAG = 961

§

XAU = 959

§

XBA = 955

§

XBB = 956

§

XBC = 957

§

XBD = 958

§

XCD = 951

§

XDR = 960

§

XOF = 952

§

XPD = 964

§

XPF = 953

§

XPT = 962

§

XSU = 994

§

XTS = 963

§

XUA = 965

§

XXX = 999

§

YER = 886

§

ZAR = 710

§

ZMW = 967

§

ZWL = 932

Implementations§

Source§

impl CurrencyCode

Source

pub fn alpha(&self) -> &'static str

alphabetic code represented by three letters.

Source

pub fn num(&self) -> u32

numeric code represented by a three-digit number code.

Source

pub fn name(&self) -> &'static str

Currency name.

Source

pub fn digit(&self) -> Option<u32>

The number of digits after the decimal separator.

Trait Implementations§

Source§

impl Clone for CurrencyCode

Source§

fn clone(&self) -> CurrencyCode

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for CurrencyCode

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<CurrencyCode> for &str

Source§

fn from(v: CurrencyCode) -> Self

Converts to this type from the input type.
Source§

impl From<CurrencyCode> for u32

Source§

fn from(v: CurrencyCode) -> Self

Converts to this type from the input type.
Source§

impl FromStr for CurrencyCode

Source§

type Err = ParseCodeError

The associated error which can be returned from parsing.
Source§

fn from_str(v: &str) -> Result<Self, Self::Err>

Parses a string s to return a value of this type. Read more
Source§

impl PartialEq for CurrencyCode

Source§

fn eq(&self, other: &CurrencyCode) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl TryFrom<&str> for CurrencyCode

Source§

type Error = ParseCodeError

The type returned in the event of a conversion error.
Source§

fn try_from(v: &str) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<u32> for CurrencyCode

Source§

type Error = ParseCodeError

The type returned in the event of a conversion error.
Source§

fn try_from(v: u32) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl Copy for CurrencyCode

Source§

impl StructuralPartialEq for CurrencyCode

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.