diff --git a/cmd/js.txt b/cmd/js.txt index 1ee9160..fc2295c 100644 --- a/cmd/js.txt +++ b/cmd/js.txt @@ -2,6 +2,6 @@ var stdCurrency = { {{- $n := len . }} {{ range $k, $v := . -}} // {{$v.Code}} currency object - {{$v.Code}}: { code: "{{$v.Code}}", name: "{{$v.Name}}", minorUnits: {{$v.Units}}, factor: {{$v.Factor}}}{{if eq (inc $k) $n}}{{else}}{{if $k}},{{end}}{{if eq $k 0}},{{end}}{{end}} + {{$v.Code}}: { code: "{{$v.Code}}", name: "{{$v.Name}}", minorUnits: {{$v.Units}}, factor: {{$v.Factor}}, name: "{{$v.Name}}"}{{if eq (inc $k) $n}}{{else}}{{if $k}},{{end}}{{if eq $k 0}},{{end}}{{end}} {{ end -}} }; diff --git a/cmd/kotlin.txt b/cmd/kotlin.txt index e092925..b7b618a 100644 --- a/cmd/kotlin.txt +++ b/cmd/kotlin.txt @@ -1,10 +1,10 @@ -data class Currency(val currencyCode: String, val minorUnits: Int, val factor: Int) { +data class Currency(val currencyCode: String, val minorUnits: Int, val factor: Int, val name: String) { companion object { val currencyMap = mapOf( {{- $n := len . }} {{ range $k, $v := . -}} - "{{$v.Code}}" to Currency("{{$v.Code}}", {{$v.Units}}, {{$v.Factor}}){{if eq (inc $k) $n}}{{else}}{{if $k}},{{end}}{{if eq $k 0}},{{end}}{{end}} + "{{$v.Code}}" to Currency("{{$v.Code}}", {{$v.Units}}, {{$v.Factor}}, "{{$v.Name}}"){{if eq (inc $k) $n}}{{else}}{{if $k}},{{end}}{{if eq $k 0}},{{end}}{{end}} {{ end -}} ) } -} \ No newline at end of file +} diff --git a/cmd/std.txt b/cmd/std.txt index cfb4d0b..6760546 100644 --- a/cmd/std.txt +++ b/cmd/std.txt @@ -14,6 +14,7 @@ type Currency struct { code string minorUnits int factor int + name string } // Code returns the currency code to the user @@ -22,6 +23,9 @@ func (c *Currency) Code() string { return c.code } // MinorUnits returns the minor unit to the user func (c *Currency) MinorUnits() int { return c.minorUnits } +// Name returns the currency name as defined in the ISO. +func (c *Currency) Name() string { return c.name } + // Factor returns the factor by which a float should be multiplied // to get back to it's smallest denomination // @@ -63,7 +67,7 @@ func Valid(code string) bool { var ( {{ range $k, $v := . -}} // {{$v.Code}} currency struct - {{$v.Code}} = Currency{ code: "{{$v.Code}}", minorUnits: {{$v.Units}}, factor: {{$v.Factor}}} + {{$v.Code}} = Currency{ code: "{{$v.Code}}", minorUnits: {{$v.Units}}, factor: {{$v.Factor}}, name: "{{$v.Name}}"} {{ end }} ) diff --git a/cmd/swift.txt b/cmd/swift.txt index a8d07de..4281a81 100644 --- a/cmd/swift.txt +++ b/cmd/swift.txt @@ -9,11 +9,14 @@ struct Currency { /// The factor to divide the currency figure by before handing to a currency formatter var factor: Int + + /// The `ISO 4217` currency name + var name: String } class Currencies { {{ range $k, $v := . -}} - static let {{$v.Code}}: Currency = Currency(code: "{{$v.Code}}", minorUnits: {{$v.Units}}, factor: {{$v.Factor}}) + static let {{$v.Code}}: Currency = Currency(code: "{{$v.Code}}", minorUnits: {{$v.Units}}, factor: {{$v.Factor}}, name: "{{$v.Name}}") {{ end }} static let allCurrencies: [String: Currency] = diff --git a/std.go b/std.go index 53bdeff..3b58ad1 100644 --- a/std.go +++ b/std.go @@ -14,6 +14,7 @@ type Currency struct { code string minorUnits int factor int + name string } // Code returns the currency code to the user @@ -22,6 +23,9 @@ func (c *Currency) Code() string { return c.code } // MinorUnits returns the minor unit to the user func (c *Currency) MinorUnits() int { return c.minorUnits } +// Name returns the currency name as defined in the ISO. +func (c *Currency) Name() string { return c.name } + // Factor returns the factor by which a float should be multiplied // to get back to it's smallest denomination // @@ -63,365 +67,365 @@ func Valid(code string) bool { // Following are all the structs containing currency data var ( // AED currency struct - AED = Currency{code: "AED", minorUnits: 2, factor: 100} + AED = Currency{code: "AED", minorUnits: 2, factor: 100, name: "UAE Dirham"} // AFN currency struct - AFN = Currency{code: "AFN", minorUnits: 2, factor: 100} + AFN = Currency{code: "AFN", minorUnits: 2, factor: 100, name: "Afghani"} // ALL currency struct - ALL = Currency{code: "ALL", minorUnits: 2, factor: 100} + ALL = Currency{code: "ALL", minorUnits: 2, factor: 100, name: "Lek"} // AMD currency struct - AMD = Currency{code: "AMD", minorUnits: 2, factor: 100} + AMD = Currency{code: "AMD", minorUnits: 2, factor: 100, name: "Armenian Dram"} // ANG currency struct - ANG = Currency{code: "ANG", minorUnits: 2, factor: 100} + ANG = Currency{code: "ANG", minorUnits: 2, factor: 100, name: "Netherlands Antillean Guilder"} // AOA currency struct - AOA = Currency{code: "AOA", minorUnits: 2, factor: 100} + AOA = Currency{code: "AOA", minorUnits: 2, factor: 100, name: "Kwanza"} // ARS currency struct - ARS = Currency{code: "ARS", minorUnits: 2, factor: 100} + ARS = Currency{code: "ARS", minorUnits: 2, factor: 100, name: "Argentine Peso"} // AUD currency struct - AUD = Currency{code: "AUD", minorUnits: 2, factor: 100} + AUD = Currency{code: "AUD", minorUnits: 2, factor: 100, name: "Australian Dollar"} // AWG currency struct - AWG = Currency{code: "AWG", minorUnits: 2, factor: 100} + AWG = Currency{code: "AWG", minorUnits: 2, factor: 100, name: "Aruban Florin"} // AZN currency struct - AZN = Currency{code: "AZN", minorUnits: 2, factor: 100} + AZN = Currency{code: "AZN", minorUnits: 2, factor: 100, name: "Azerbaijan Manat"} // BAM currency struct - BAM = Currency{code: "BAM", minorUnits: 2, factor: 100} + BAM = Currency{code: "BAM", minorUnits: 2, factor: 100, name: "Convertible Mark"} // BBD currency struct - BBD = Currency{code: "BBD", minorUnits: 2, factor: 100} + BBD = Currency{code: "BBD", minorUnits: 2, factor: 100, name: "Barbados Dollar"} // BDT currency struct - BDT = Currency{code: "BDT", minorUnits: 2, factor: 100} + BDT = Currency{code: "BDT", minorUnits: 2, factor: 100, name: "Taka"} // BGN currency struct - BGN = Currency{code: "BGN", minorUnits: 2, factor: 100} + BGN = Currency{code: "BGN", minorUnits: 2, factor: 100, name: "Bulgarian Lev"} // BHD currency struct - BHD = Currency{code: "BHD", minorUnits: 3, factor: 1000} + BHD = Currency{code: "BHD", minorUnits: 3, factor: 1000, name: "Bahraini Dinar"} // BIF currency struct - BIF = Currency{code: "BIF", minorUnits: 0, factor: 1} + BIF = Currency{code: "BIF", minorUnits: 0, factor: 1, name: "Burundi Franc"} // BMD currency struct - BMD = Currency{code: "BMD", minorUnits: 2, factor: 100} + BMD = Currency{code: "BMD", minorUnits: 2, factor: 100, name: "Bermudian Dollar"} // BND currency struct - BND = Currency{code: "BND", minorUnits: 2, factor: 100} + BND = Currency{code: "BND", minorUnits: 2, factor: 100, name: "Brunei Dollar"} // BOB currency struct - BOB = Currency{code: "BOB", minorUnits: 2, factor: 100} + BOB = Currency{code: "BOB", minorUnits: 2, factor: 100, name: "Boliviano"} // BOV currency struct - BOV = Currency{code: "BOV", minorUnits: 2, factor: 100} + BOV = Currency{code: "BOV", minorUnits: 2, factor: 100, name: "Mvdol"} // BRL currency struct - BRL = Currency{code: "BRL", minorUnits: 2, factor: 100} + BRL = Currency{code: "BRL", minorUnits: 2, factor: 100, name: "Brazilian Real"} // BSD currency struct - BSD = Currency{code: "BSD", minorUnits: 2, factor: 100} + BSD = Currency{code: "BSD", minorUnits: 2, factor: 100, name: "Bahamian Dollar"} // BTN currency struct - BTN = Currency{code: "BTN", minorUnits: 2, factor: 100} + BTN = Currency{code: "BTN", minorUnits: 2, factor: 100, name: "Ngultrum"} // BWP currency struct - BWP = Currency{code: "BWP", minorUnits: 2, factor: 100} + BWP = Currency{code: "BWP", minorUnits: 2, factor: 100, name: "Pula"} // BYN currency struct - BYN = Currency{code: "BYN", minorUnits: 2, factor: 100} + BYN = Currency{code: "BYN", minorUnits: 2, factor: 100, name: "Belarusian Ruble"} // BZD currency struct - BZD = Currency{code: "BZD", minorUnits: 2, factor: 100} + BZD = Currency{code: "BZD", minorUnits: 2, factor: 100, name: "Belize Dollar"} // CAD currency struct - CAD = Currency{code: "CAD", minorUnits: 2, factor: 100} + CAD = Currency{code: "CAD", minorUnits: 2, factor: 100, name: "Canadian Dollar"} // CDF currency struct - CDF = Currency{code: "CDF", minorUnits: 2, factor: 100} + CDF = Currency{code: "CDF", minorUnits: 2, factor: 100, name: "Congolese Franc"} // CHE currency struct - CHE = Currency{code: "CHE", minorUnits: 2, factor: 100} + CHE = Currency{code: "CHE", minorUnits: 2, factor: 100, name: "WIR Euro"} // CHF currency struct - CHF = Currency{code: "CHF", minorUnits: 2, factor: 100} + CHF = Currency{code: "CHF", minorUnits: 2, factor: 100, name: "Swiss Franc"} // CHW currency struct - CHW = Currency{code: "CHW", minorUnits: 2, factor: 100} + CHW = Currency{code: "CHW", minorUnits: 2, factor: 100, name: "WIR Franc"} // CLF currency struct - CLF = Currency{code: "CLF", minorUnits: 4, factor: 10000} + CLF = Currency{code: "CLF", minorUnits: 4, factor: 10000, name: "Unidad de Fomento"} // CLP currency struct - CLP = Currency{code: "CLP", minorUnits: 0, factor: 1} + CLP = Currency{code: "CLP", minorUnits: 0, factor: 1, name: "Chilean Peso"} // CNY currency struct - CNY = Currency{code: "CNY", minorUnits: 2, factor: 100} + CNY = Currency{code: "CNY", minorUnits: 2, factor: 100, name: "Yuan Renminbi"} // COP currency struct - COP = Currency{code: "COP", minorUnits: 2, factor: 100} + COP = Currency{code: "COP", minorUnits: 2, factor: 100, name: "Colombian Peso"} // COU currency struct - COU = Currency{code: "COU", minorUnits: 2, factor: 100} + COU = Currency{code: "COU", minorUnits: 2, factor: 100, name: "Unidad de Valor Real"} // CRC currency struct - CRC = Currency{code: "CRC", minorUnits: 2, factor: 100} + CRC = Currency{code: "CRC", minorUnits: 2, factor: 100, name: "Costa Rican Colon"} // CUC currency struct - CUC = Currency{code: "CUC", minorUnits: 2, factor: 100} + CUC = Currency{code: "CUC", minorUnits: 2, factor: 100, name: "Peso Convertible"} // CUP currency struct - CUP = Currency{code: "CUP", minorUnits: 2, factor: 100} + CUP = Currency{code: "CUP", minorUnits: 2, factor: 100, name: "Cuban Peso"} // CVE currency struct - CVE = Currency{code: "CVE", minorUnits: 2, factor: 100} + CVE = Currency{code: "CVE", minorUnits: 2, factor: 100, name: "Cabo Verde Escudo"} // CZK currency struct - CZK = Currency{code: "CZK", minorUnits: 2, factor: 100} + CZK = Currency{code: "CZK", minorUnits: 2, factor: 100, name: "Czech Koruna"} // DJF currency struct - DJF = Currency{code: "DJF", minorUnits: 0, factor: 1} + DJF = Currency{code: "DJF", minorUnits: 0, factor: 1, name: "Djibouti Franc"} // DKK currency struct - DKK = Currency{code: "DKK", minorUnits: 2, factor: 100} + DKK = Currency{code: "DKK", minorUnits: 2, factor: 100, name: "Danish Krone"} // DOP currency struct - DOP = Currency{code: "DOP", minorUnits: 2, factor: 100} + DOP = Currency{code: "DOP", minorUnits: 2, factor: 100, name: "Dominican Peso"} // DZD currency struct - DZD = Currency{code: "DZD", minorUnits: 2, factor: 100} + DZD = Currency{code: "DZD", minorUnits: 2, factor: 100, name: "Algerian Dinar"} // EGP currency struct - EGP = Currency{code: "EGP", minorUnits: 2, factor: 100} + EGP = Currency{code: "EGP", minorUnits: 2, factor: 100, name: "Egyptian Pound"} // ERN currency struct - ERN = Currency{code: "ERN", minorUnits: 2, factor: 100} + ERN = Currency{code: "ERN", minorUnits: 2, factor: 100, name: "Nakfa"} // ETB currency struct - ETB = Currency{code: "ETB", minorUnits: 2, factor: 100} + ETB = Currency{code: "ETB", minorUnits: 2, factor: 100, name: "Ethiopian Birr"} // EUR currency struct - EUR = Currency{code: "EUR", minorUnits: 2, factor: 100} + EUR = Currency{code: "EUR", minorUnits: 2, factor: 100, name: "Euro"} // FJD currency struct - FJD = Currency{code: "FJD", minorUnits: 2, factor: 100} + FJD = Currency{code: "FJD", minorUnits: 2, factor: 100, name: "Fiji Dollar"} // FKP currency struct - FKP = Currency{code: "FKP", minorUnits: 2, factor: 100} + FKP = Currency{code: "FKP", minorUnits: 2, factor: 100, name: "Falkland Islands Pound"} // GBP currency struct - GBP = Currency{code: "GBP", minorUnits: 2, factor: 100} + GBP = Currency{code: "GBP", minorUnits: 2, factor: 100, name: "Pound Sterling"} // GEL currency struct - GEL = Currency{code: "GEL", minorUnits: 2, factor: 100} + GEL = Currency{code: "GEL", minorUnits: 2, factor: 100, name: "Lari"} // GHS currency struct - GHS = Currency{code: "GHS", minorUnits: 2, factor: 100} + GHS = Currency{code: "GHS", minorUnits: 2, factor: 100, name: "Ghana Cedi"} // GIP currency struct - GIP = Currency{code: "GIP", minorUnits: 2, factor: 100} + GIP = Currency{code: "GIP", minorUnits: 2, factor: 100, name: "Gibraltar Pound"} // GMD currency struct - GMD = Currency{code: "GMD", minorUnits: 2, factor: 100} + GMD = Currency{code: "GMD", minorUnits: 2, factor: 100, name: "Dalasi"} // GNF currency struct - GNF = Currency{code: "GNF", minorUnits: 0, factor: 1} + GNF = Currency{code: "GNF", minorUnits: 0, factor: 1, name: "Guinean Franc"} // GTQ currency struct - GTQ = Currency{code: "GTQ", minorUnits: 2, factor: 100} + GTQ = Currency{code: "GTQ", minorUnits: 2, factor: 100, name: "Quetzal"} // GYD currency struct - GYD = Currency{code: "GYD", minorUnits: 2, factor: 100} + GYD = Currency{code: "GYD", minorUnits: 2, factor: 100, name: "Guyana Dollar"} // HKD currency struct - HKD = Currency{code: "HKD", minorUnits: 2, factor: 100} + HKD = Currency{code: "HKD", minorUnits: 2, factor: 100, name: "Hong Kong Dollar"} // HNL currency struct - HNL = Currency{code: "HNL", minorUnits: 2, factor: 100} + HNL = Currency{code: "HNL", minorUnits: 2, factor: 100, name: "Lempira"} // HTG currency struct - HTG = Currency{code: "HTG", minorUnits: 2, factor: 100} + HTG = Currency{code: "HTG", minorUnits: 2, factor: 100, name: "Gourde"} // HUF currency struct - HUF = Currency{code: "HUF", minorUnits: 2, factor: 100} + HUF = Currency{code: "HUF", minorUnits: 2, factor: 100, name: "Forint"} // IDR currency struct - IDR = Currency{code: "IDR", minorUnits: 2, factor: 100} + IDR = Currency{code: "IDR", minorUnits: 2, factor: 100, name: "Rupiah"} // ILS currency struct - ILS = Currency{code: "ILS", minorUnits: 2, factor: 100} + ILS = Currency{code: "ILS", minorUnits: 2, factor: 100, name: "New Israeli Sheqel"} // INR currency struct - INR = Currency{code: "INR", minorUnits: 2, factor: 100} + INR = Currency{code: "INR", minorUnits: 2, factor: 100, name: "Indian Rupee"} // IQD currency struct - IQD = Currency{code: "IQD", minorUnits: 3, factor: 1000} + IQD = Currency{code: "IQD", minorUnits: 3, factor: 1000, name: "Iraqi Dinar"} // IRR currency struct - IRR = Currency{code: "IRR", minorUnits: 2, factor: 100} + IRR = Currency{code: "IRR", minorUnits: 2, factor: 100, name: "Iranian Rial"} // ISK currency struct - ISK = Currency{code: "ISK", minorUnits: 0, factor: 1} + ISK = Currency{code: "ISK", minorUnits: 0, factor: 1, name: "Iceland Krona"} // JMD currency struct - JMD = Currency{code: "JMD", minorUnits: 2, factor: 100} + JMD = Currency{code: "JMD", minorUnits: 2, factor: 100, name: "Jamaican Dollar"} // JOD currency struct - JOD = Currency{code: "JOD", minorUnits: 3, factor: 1000} + JOD = Currency{code: "JOD", minorUnits: 3, factor: 1000, name: "Jordanian Dinar"} // JPY currency struct - JPY = Currency{code: "JPY", minorUnits: 0, factor: 1} + JPY = Currency{code: "JPY", minorUnits: 0, factor: 1, name: "Yen"} // KES currency struct - KES = Currency{code: "KES", minorUnits: 2, factor: 100} + KES = Currency{code: "KES", minorUnits: 2, factor: 100, name: "Kenyan Shilling"} // KGS currency struct - KGS = Currency{code: "KGS", minorUnits: 2, factor: 100} + KGS = Currency{code: "KGS", minorUnits: 2, factor: 100, name: "Som"} // KHR currency struct - KHR = Currency{code: "KHR", minorUnits: 2, factor: 100} + KHR = Currency{code: "KHR", minorUnits: 2, factor: 100, name: "Riel"} // KMF currency struct - KMF = Currency{code: "KMF", minorUnits: 0, factor: 1} + KMF = Currency{code: "KMF", minorUnits: 0, factor: 1, name: "Comorian Franc "} // KPW currency struct - KPW = Currency{code: "KPW", minorUnits: 2, factor: 100} + KPW = Currency{code: "KPW", minorUnits: 2, factor: 100, name: "North Korean Won"} // KRW currency struct - KRW = Currency{code: "KRW", minorUnits: 0, factor: 1} + KRW = Currency{code: "KRW", minorUnits: 0, factor: 1, name: "Won"} // KWD currency struct - KWD = Currency{code: "KWD", minorUnits: 3, factor: 1000} + KWD = Currency{code: "KWD", minorUnits: 3, factor: 1000, name: "Kuwaiti Dinar"} // KYD currency struct - KYD = Currency{code: "KYD", minorUnits: 2, factor: 100} + KYD = Currency{code: "KYD", minorUnits: 2, factor: 100, name: "Cayman Islands Dollar"} // KZT currency struct - KZT = Currency{code: "KZT", minorUnits: 2, factor: 100} + KZT = Currency{code: "KZT", minorUnits: 2, factor: 100, name: "Tenge"} // LAK currency struct - LAK = Currency{code: "LAK", minorUnits: 2, factor: 100} + LAK = Currency{code: "LAK", minorUnits: 2, factor: 100, name: "Lao Kip"} // LBP currency struct - LBP = Currency{code: "LBP", minorUnits: 2, factor: 100} + LBP = Currency{code: "LBP", minorUnits: 2, factor: 100, name: "Lebanese Pound"} // LKR currency struct - LKR = Currency{code: "LKR", minorUnits: 2, factor: 100} + LKR = Currency{code: "LKR", minorUnits: 2, factor: 100, name: "Sri Lanka Rupee"} // LRD currency struct - LRD = Currency{code: "LRD", minorUnits: 2, factor: 100} + LRD = Currency{code: "LRD", minorUnits: 2, factor: 100, name: "Liberian Dollar"} // LSL currency struct - LSL = Currency{code: "LSL", minorUnits: 2, factor: 100} + LSL = Currency{code: "LSL", minorUnits: 2, factor: 100, name: "Loti"} // LYD currency struct - LYD = Currency{code: "LYD", minorUnits: 3, factor: 1000} + LYD = Currency{code: "LYD", minorUnits: 3, factor: 1000, name: "Libyan Dinar"} // MAD currency struct - MAD = Currency{code: "MAD", minorUnits: 2, factor: 100} + MAD = Currency{code: "MAD", minorUnits: 2, factor: 100, name: "Moroccan Dirham"} // MDL currency struct - MDL = Currency{code: "MDL", minorUnits: 2, factor: 100} + MDL = Currency{code: "MDL", minorUnits: 2, factor: 100, name: "Moldovan Leu"} // MGA currency struct - MGA = Currency{code: "MGA", minorUnits: 2, factor: 100} + MGA = Currency{code: "MGA", minorUnits: 2, factor: 100, name: "Malagasy Ariary"} // MKD currency struct - MKD = Currency{code: "MKD", minorUnits: 2, factor: 100} + MKD = Currency{code: "MKD", minorUnits: 2, factor: 100, name: "Denar"} // MMK currency struct - MMK = Currency{code: "MMK", minorUnits: 2, factor: 100} + MMK = Currency{code: "MMK", minorUnits: 2, factor: 100, name: "Kyat"} // MNT currency struct - MNT = Currency{code: "MNT", minorUnits: 2, factor: 100} + MNT = Currency{code: "MNT", minorUnits: 2, factor: 100, name: "Tugrik"} // MOP currency struct - MOP = Currency{code: "MOP", minorUnits: 2, factor: 100} + MOP = Currency{code: "MOP", minorUnits: 2, factor: 100, name: "Pataca"} // MRU currency struct - MRU = Currency{code: "MRU", minorUnits: 2, factor: 100} + MRU = Currency{code: "MRU", minorUnits: 2, factor: 100, name: "Ouguiya"} // MUR currency struct - MUR = Currency{code: "MUR", minorUnits: 2, factor: 100} + MUR = Currency{code: "MUR", minorUnits: 2, factor: 100, name: "Mauritius Rupee"} // MVR currency struct - MVR = Currency{code: "MVR", minorUnits: 2, factor: 100} + MVR = Currency{code: "MVR", minorUnits: 2, factor: 100, name: "Rufiyaa"} // MWK currency struct - MWK = Currency{code: "MWK", minorUnits: 2, factor: 100} + MWK = Currency{code: "MWK", minorUnits: 2, factor: 100, name: "Malawi Kwacha"} // MXN currency struct - MXN = Currency{code: "MXN", minorUnits: 2, factor: 100} + MXN = Currency{code: "MXN", minorUnits: 2, factor: 100, name: "Mexican Peso"} // MXV currency struct - MXV = Currency{code: "MXV", minorUnits: 2, factor: 100} + MXV = Currency{code: "MXV", minorUnits: 2, factor: 100, name: "Mexican Unidad de Inversion (UDI)"} // MYR currency struct - MYR = Currency{code: "MYR", minorUnits: 2, factor: 100} + MYR = Currency{code: "MYR", minorUnits: 2, factor: 100, name: "Malaysian Ringgit"} // MZN currency struct - MZN = Currency{code: "MZN", minorUnits: 2, factor: 100} + MZN = Currency{code: "MZN", minorUnits: 2, factor: 100, name: "Mozambique Metical"} // NAD currency struct - NAD = Currency{code: "NAD", minorUnits: 2, factor: 100} + NAD = Currency{code: "NAD", minorUnits: 2, factor: 100, name: "Namibia Dollar"} // NGN currency struct - NGN = Currency{code: "NGN", minorUnits: 2, factor: 100} + NGN = Currency{code: "NGN", minorUnits: 2, factor: 100, name: "Naira"} // NIO currency struct - NIO = Currency{code: "NIO", minorUnits: 2, factor: 100} + NIO = Currency{code: "NIO", minorUnits: 2, factor: 100, name: "Cordoba Oro"} // NOK currency struct - NOK = Currency{code: "NOK", minorUnits: 2, factor: 100} + NOK = Currency{code: "NOK", minorUnits: 2, factor: 100, name: "Norwegian Krone"} // NPR currency struct - NPR = Currency{code: "NPR", minorUnits: 2, factor: 100} + NPR = Currency{code: "NPR", minorUnits: 2, factor: 100, name: "Nepalese Rupee"} // NZD currency struct - NZD = Currency{code: "NZD", minorUnits: 2, factor: 100} + NZD = Currency{code: "NZD", minorUnits: 2, factor: 100, name: "New Zealand Dollar"} // OMR currency struct - OMR = Currency{code: "OMR", minorUnits: 3, factor: 1000} + OMR = Currency{code: "OMR", minorUnits: 3, factor: 1000, name: "Rial Omani"} // PAB currency struct - PAB = Currency{code: "PAB", minorUnits: 2, factor: 100} + PAB = Currency{code: "PAB", minorUnits: 2, factor: 100, name: "Balboa"} // PEN currency struct - PEN = Currency{code: "PEN", minorUnits: 2, factor: 100} + PEN = Currency{code: "PEN", minorUnits: 2, factor: 100, name: "Sol"} // PGK currency struct - PGK = Currency{code: "PGK", minorUnits: 2, factor: 100} + PGK = Currency{code: "PGK", minorUnits: 2, factor: 100, name: "Kina"} // PHP currency struct - PHP = Currency{code: "PHP", minorUnits: 2, factor: 100} + PHP = Currency{code: "PHP", minorUnits: 2, factor: 100, name: "Philippine Peso"} // PKR currency struct - PKR = Currency{code: "PKR", minorUnits: 2, factor: 100} + PKR = Currency{code: "PKR", minorUnits: 2, factor: 100, name: "Pakistan Rupee"} // PLN currency struct - PLN = Currency{code: "PLN", minorUnits: 2, factor: 100} + PLN = Currency{code: "PLN", minorUnits: 2, factor: 100, name: "Zloty"} // PYG currency struct - PYG = Currency{code: "PYG", minorUnits: 0, factor: 1} + PYG = Currency{code: "PYG", minorUnits: 0, factor: 1, name: "Guarani"} // QAR currency struct - QAR = Currency{code: "QAR", minorUnits: 2, factor: 100} + QAR = Currency{code: "QAR", minorUnits: 2, factor: 100, name: "Qatari Rial"} // RON currency struct - RON = Currency{code: "RON", minorUnits: 2, factor: 100} + RON = Currency{code: "RON", minorUnits: 2, factor: 100, name: "Romanian Leu"} // RSD currency struct - RSD = Currency{code: "RSD", minorUnits: 2, factor: 100} + RSD = Currency{code: "RSD", minorUnits: 2, factor: 100, name: "Serbian Dinar"} // RUB currency struct - RUB = Currency{code: "RUB", minorUnits: 2, factor: 100} + RUB = Currency{code: "RUB", minorUnits: 2, factor: 100, name: "Russian Ruble"} // RWF currency struct - RWF = Currency{code: "RWF", minorUnits: 0, factor: 1} + RWF = Currency{code: "RWF", minorUnits: 0, factor: 1, name: "Rwanda Franc"} // SAR currency struct - SAR = Currency{code: "SAR", minorUnits: 2, factor: 100} + SAR = Currency{code: "SAR", minorUnits: 2, factor: 100, name: "Saudi Riyal"} // SBD currency struct - SBD = Currency{code: "SBD", minorUnits: 2, factor: 100} + SBD = Currency{code: "SBD", minorUnits: 2, factor: 100, name: "Solomon Islands Dollar"} // SCR currency struct - SCR = Currency{code: "SCR", minorUnits: 2, factor: 100} + SCR = Currency{code: "SCR", minorUnits: 2, factor: 100, name: "Seychelles Rupee"} // SDG currency struct - SDG = Currency{code: "SDG", minorUnits: 2, factor: 100} + SDG = Currency{code: "SDG", minorUnits: 2, factor: 100, name: "Sudanese Pound"} // SEK currency struct - SEK = Currency{code: "SEK", minorUnits: 2, factor: 100} + SEK = Currency{code: "SEK", minorUnits: 2, factor: 100, name: "Swedish Krona"} // SGD currency struct - SGD = Currency{code: "SGD", minorUnits: 2, factor: 100} + SGD = Currency{code: "SGD", minorUnits: 2, factor: 100, name: "Singapore Dollar"} // SHP currency struct - SHP = Currency{code: "SHP", minorUnits: 2, factor: 100} + SHP = Currency{code: "SHP", minorUnits: 2, factor: 100, name: "Saint Helena Pound"} // SLE currency struct - SLE = Currency{code: "SLE", minorUnits: 2, factor: 100} + SLE = Currency{code: "SLE", minorUnits: 2, factor: 100, name: "Leone"} // SOS currency struct - SOS = Currency{code: "SOS", minorUnits: 2, factor: 100} + SOS = Currency{code: "SOS", minorUnits: 2, factor: 100, name: "Somali Shilling"} // SRD currency struct - SRD = Currency{code: "SRD", minorUnits: 2, factor: 100} + SRD = Currency{code: "SRD", minorUnits: 2, factor: 100, name: "Surinam Dollar"} // SSP currency struct - SSP = Currency{code: "SSP", minorUnits: 2, factor: 100} + SSP = Currency{code: "SSP", minorUnits: 2, factor: 100, name: "South Sudanese Pound"} // STN currency struct - STN = Currency{code: "STN", minorUnits: 2, factor: 100} + STN = Currency{code: "STN", minorUnits: 2, factor: 100, name: "Dobra"} // SVC currency struct - SVC = Currency{code: "SVC", minorUnits: 2, factor: 100} + SVC = Currency{code: "SVC", minorUnits: 2, factor: 100, name: "El Salvador Colon"} // SYP currency struct - SYP = Currency{code: "SYP", minorUnits: 2, factor: 100} + SYP = Currency{code: "SYP", minorUnits: 2, factor: 100, name: "Syrian Pound"} // SZL currency struct - SZL = Currency{code: "SZL", minorUnits: 2, factor: 100} + SZL = Currency{code: "SZL", minorUnits: 2, factor: 100, name: "Lilangeni"} // THB currency struct - THB = Currency{code: "THB", minorUnits: 2, factor: 100} + THB = Currency{code: "THB", minorUnits: 2, factor: 100, name: "Baht"} // TJS currency struct - TJS = Currency{code: "TJS", minorUnits: 2, factor: 100} + TJS = Currency{code: "TJS", minorUnits: 2, factor: 100, name: "Somoni"} // TMT currency struct - TMT = Currency{code: "TMT", minorUnits: 2, factor: 100} + TMT = Currency{code: "TMT", minorUnits: 2, factor: 100, name: "Turkmenistan New Manat"} // TND currency struct - TND = Currency{code: "TND", minorUnits: 3, factor: 1000} + TND = Currency{code: "TND", minorUnits: 3, factor: 1000, name: "Tunisian Dinar"} // TOP currency struct - TOP = Currency{code: "TOP", minorUnits: 2, factor: 100} + TOP = Currency{code: "TOP", minorUnits: 2, factor: 100, name: "Pa’anga"} // TRY currency struct - TRY = Currency{code: "TRY", minorUnits: 2, factor: 100} + TRY = Currency{code: "TRY", minorUnits: 2, factor: 100, name: "Turkish Lira"} // TTD currency struct - TTD = Currency{code: "TTD", minorUnits: 2, factor: 100} + TTD = Currency{code: "TTD", minorUnits: 2, factor: 100, name: "Trinidad and Tobago Dollar"} // TWD currency struct - TWD = Currency{code: "TWD", minorUnits: 2, factor: 100} + TWD = Currency{code: "TWD", minorUnits: 2, factor: 100, name: "New Taiwan Dollar"} // TZS currency struct - TZS = Currency{code: "TZS", minorUnits: 2, factor: 100} + TZS = Currency{code: "TZS", minorUnits: 2, factor: 100, name: "Tanzanian Shilling"} // UAH currency struct - UAH = Currency{code: "UAH", minorUnits: 2, factor: 100} + UAH = Currency{code: "UAH", minorUnits: 2, factor: 100, name: "Hryvnia"} // UGX currency struct - UGX = Currency{code: "UGX", minorUnits: 0, factor: 1} + UGX = Currency{code: "UGX", minorUnits: 0, factor: 1, name: "Uganda Shilling"} // USD currency struct - USD = Currency{code: "USD", minorUnits: 2, factor: 100} + USD = Currency{code: "USD", minorUnits: 2, factor: 100, name: "US Dollar"} // USN currency struct - USN = Currency{code: "USN", minorUnits: 2, factor: 100} + USN = Currency{code: "USN", minorUnits: 2, factor: 100, name: "US Dollar (Next day)"} // UYI currency struct - UYI = Currency{code: "UYI", minorUnits: 0, factor: 1} + UYI = Currency{code: "UYI", minorUnits: 0, factor: 1, name: "Uruguay Peso en Unidades Indexadas (UI)"} // UYU currency struct - UYU = Currency{code: "UYU", minorUnits: 2, factor: 100} + UYU = Currency{code: "UYU", minorUnits: 2, factor: 100, name: "Peso Uruguayo"} // UYW currency struct - UYW = Currency{code: "UYW", minorUnits: 4, factor: 10000} + UYW = Currency{code: "UYW", minorUnits: 4, factor: 10000, name: "Unidad Previsional"} // UZS currency struct - UZS = Currency{code: "UZS", minorUnits: 2, factor: 100} + UZS = Currency{code: "UZS", minorUnits: 2, factor: 100, name: "Uzbekistan Sum"} // VED currency struct - VED = Currency{code: "VED", minorUnits: 2, factor: 100} + VED = Currency{code: "VED", minorUnits: 2, factor: 100, name: "Bolívar Soberano"} // VES currency struct - VES = Currency{code: "VES", minorUnits: 2, factor: 100} + VES = Currency{code: "VES", minorUnits: 2, factor: 100, name: "Bolívar Soberano"} // VND currency struct - VND = Currency{code: "VND", minorUnits: 0, factor: 1} + VND = Currency{code: "VND", minorUnits: 0, factor: 1, name: "Dong"} // VUV currency struct - VUV = Currency{code: "VUV", minorUnits: 0, factor: 1} + VUV = Currency{code: "VUV", minorUnits: 0, factor: 1, name: "Vatu"} // WST currency struct - WST = Currency{code: "WST", minorUnits: 2, factor: 100} + WST = Currency{code: "WST", minorUnits: 2, factor: 100, name: "Tala"} // XAF currency struct - XAF = Currency{code: "XAF", minorUnits: 0, factor: 1} + XAF = Currency{code: "XAF", minorUnits: 0, factor: 1, name: "CFA Franc BEAC"} // XAG currency struct - XAG = Currency{code: "XAG", minorUnits: 0, factor: 1} + XAG = Currency{code: "XAG", minorUnits: 0, factor: 1, name: "Silver"} // XAU currency struct - XAU = Currency{code: "XAU", minorUnits: 0, factor: 1} + XAU = Currency{code: "XAU", minorUnits: 0, factor: 1, name: "Gold"} // XBA currency struct - XBA = Currency{code: "XBA", minorUnits: 0, factor: 1} + XBA = Currency{code: "XBA", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Composite Unit (EURCO)"} // XBB currency struct - XBB = Currency{code: "XBB", minorUnits: 0, factor: 1} + XBB = Currency{code: "XBB", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Monetary Unit (E.M.U.-6)"} // XBC currency struct - XBC = Currency{code: "XBC", minorUnits: 0, factor: 1} + XBC = Currency{code: "XBC", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Unit of Account 9 (E.U.A.-9)"} // XBD currency struct - XBD = Currency{code: "XBD", minorUnits: 0, factor: 1} + XBD = Currency{code: "XBD", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Unit of Account 17 (E.U.A.-17)"} // XCD currency struct - XCD = Currency{code: "XCD", minorUnits: 2, factor: 100} + XCD = Currency{code: "XCD", minorUnits: 2, factor: 100, name: "East Caribbean Dollar"} // XDR currency struct - XDR = Currency{code: "XDR", minorUnits: 0, factor: 1} + XDR = Currency{code: "XDR", minorUnits: 0, factor: 1, name: "SDR (Special Drawing Right)"} // XOF currency struct - XOF = Currency{code: "XOF", minorUnits: 0, factor: 1} + XOF = Currency{code: "XOF", minorUnits: 0, factor: 1, name: "CFA Franc BCEAO"} // XPD currency struct - XPD = Currency{code: "XPD", minorUnits: 0, factor: 1} + XPD = Currency{code: "XPD", minorUnits: 0, factor: 1, name: "Palladium"} // XPF currency struct - XPF = Currency{code: "XPF", minorUnits: 0, factor: 1} + XPF = Currency{code: "XPF", minorUnits: 0, factor: 1, name: "CFP Franc"} // XPT currency struct - XPT = Currency{code: "XPT", minorUnits: 0, factor: 1} + XPT = Currency{code: "XPT", minorUnits: 0, factor: 1, name: "Platinum"} // XSU currency struct - XSU = Currency{code: "XSU", minorUnits: 0, factor: 1} + XSU = Currency{code: "XSU", minorUnits: 0, factor: 1, name: "Sucre"} // XTS currency struct - XTS = Currency{code: "XTS", minorUnits: 0, factor: 1} + XTS = Currency{code: "XTS", minorUnits: 0, factor: 1, name: "Codes specifically reserved for testing purposes"} // XUA currency struct - XUA = Currency{code: "XUA", minorUnits: 0, factor: 1} + XUA = Currency{code: "XUA", minorUnits: 0, factor: 1, name: "ADB Unit of Account"} // XXX currency struct - XXX = Currency{code: "XXX", minorUnits: 0, factor: 1} + XXX = Currency{code: "XXX", minorUnits: 0, factor: 1, name: "The codes assigned for transactions where no currency is involved"} // YER currency struct - YER = Currency{code: "YER", minorUnits: 2, factor: 100} + YER = Currency{code: "YER", minorUnits: 2, factor: 100, name: "Yemeni Rial"} // ZAR currency struct - ZAR = Currency{code: "ZAR", minorUnits: 2, factor: 100} + ZAR = Currency{code: "ZAR", minorUnits: 2, factor: 100, name: "Rand"} // ZMW currency struct - ZMW = Currency{code: "ZMW", minorUnits: 2, factor: 100} + ZMW = Currency{code: "ZMW", minorUnits: 2, factor: 100, name: "Zambian Kwacha"} // ZWG currency struct - ZWG = Currency{code: "ZWG", minorUnits: 2, factor: 100} + ZWG = Currency{code: "ZWG", minorUnits: 2, factor: 100, name: "Zimbabwe Gold"} // ZWL currency struct - ZWL = Currency{code: "ZWL", minorUnits: 2, factor: 100} + ZWL = Currency{code: "ZWL", minorUnits: 2, factor: 100, name: "Zimbabwe Dollar"} ) var currencies = map[string]Currency{ diff --git a/std.kt b/std.kt index c8ff17a..12a21ba 100644 --- a/std.kt +++ b/std.kt @@ -1,186 +1,186 @@ -data class Currency(val currencyCode: String, val minorUnits: Int, val factor: Int) { +data class Currency(val currencyCode: String, val minorUnits: Int, val factor: Int, val name: String) { companion object { val currencyMap = mapOf( - "AED" to Currency("AED", 2, 100), - "AFN" to Currency("AFN", 2, 100), - "ALL" to Currency("ALL", 2, 100), - "AMD" to Currency("AMD", 2, 100), - "ANG" to Currency("ANG", 2, 100), - "AOA" to Currency("AOA", 2, 100), - "ARS" to Currency("ARS", 2, 100), - "AUD" to Currency("AUD", 2, 100), - "AWG" to Currency("AWG", 2, 100), - "AZN" to Currency("AZN", 2, 100), - "BAM" to Currency("BAM", 2, 100), - "BBD" to Currency("BBD", 2, 100), - "BDT" to Currency("BDT", 2, 100), - "BGN" to Currency("BGN", 2, 100), - "BHD" to Currency("BHD", 3, 1000), - "BIF" to Currency("BIF", 0, 1), - "BMD" to Currency("BMD", 2, 100), - "BND" to Currency("BND", 2, 100), - "BOB" to Currency("BOB", 2, 100), - "BOV" to Currency("BOV", 2, 100), - "BRL" to Currency("BRL", 2, 100), - "BSD" to Currency("BSD", 2, 100), - "BTN" to Currency("BTN", 2, 100), - "BWP" to Currency("BWP", 2, 100), - "BYN" to Currency("BYN", 2, 100), - "BZD" to Currency("BZD", 2, 100), - "CAD" to Currency("CAD", 2, 100), - "CDF" to Currency("CDF", 2, 100), - "CHE" to Currency("CHE", 2, 100), - "CHF" to Currency("CHF", 2, 100), - "CHW" to Currency("CHW", 2, 100), - "CLF" to Currency("CLF", 4, 10000), - "CLP" to Currency("CLP", 0, 1), - "CNY" to Currency("CNY", 2, 100), - "COP" to Currency("COP", 2, 100), - "COU" to Currency("COU", 2, 100), - "CRC" to Currency("CRC", 2, 100), - "CUC" to Currency("CUC", 2, 100), - "CUP" to Currency("CUP", 2, 100), - "CVE" to Currency("CVE", 2, 100), - "CZK" to Currency("CZK", 2, 100), - "DJF" to Currency("DJF", 0, 1), - "DKK" to Currency("DKK", 2, 100), - "DOP" to Currency("DOP", 2, 100), - "DZD" to Currency("DZD", 2, 100), - "EGP" to Currency("EGP", 2, 100), - "ERN" to Currency("ERN", 2, 100), - "ETB" to Currency("ETB", 2, 100), - "EUR" to Currency("EUR", 2, 100), - "FJD" to Currency("FJD", 2, 100), - "FKP" to Currency("FKP", 2, 100), - "GBP" to Currency("GBP", 2, 100), - "GEL" to Currency("GEL", 2, 100), - "GHS" to Currency("GHS", 2, 100), - "GIP" to Currency("GIP", 2, 100), - "GMD" to Currency("GMD", 2, 100), - "GNF" to Currency("GNF", 0, 1), - "GTQ" to Currency("GTQ", 2, 100), - "GYD" to Currency("GYD", 2, 100), - "HKD" to Currency("HKD", 2, 100), - "HNL" to Currency("HNL", 2, 100), - "HTG" to Currency("HTG", 2, 100), - "HUF" to Currency("HUF", 2, 100), - "IDR" to Currency("IDR", 2, 100), - "ILS" to Currency("ILS", 2, 100), - "INR" to Currency("INR", 2, 100), - "IQD" to Currency("IQD", 3, 1000), - "IRR" to Currency("IRR", 2, 100), - "ISK" to Currency("ISK", 0, 1), - "JMD" to Currency("JMD", 2, 100), - "JOD" to Currency("JOD", 3, 1000), - "JPY" to Currency("JPY", 0, 1), - "KES" to Currency("KES", 2, 100), - "KGS" to Currency("KGS", 2, 100), - "KHR" to Currency("KHR", 2, 100), - "KMF" to Currency("KMF", 0, 1), - "KPW" to Currency("KPW", 2, 100), - "KRW" to Currency("KRW", 0, 1), - "KWD" to Currency("KWD", 3, 1000), - "KYD" to Currency("KYD", 2, 100), - "KZT" to Currency("KZT", 2, 100), - "LAK" to Currency("LAK", 2, 100), - "LBP" to Currency("LBP", 2, 100), - "LKR" to Currency("LKR", 2, 100), - "LRD" to Currency("LRD", 2, 100), - "LSL" to Currency("LSL", 2, 100), - "LYD" to Currency("LYD", 3, 1000), - "MAD" to Currency("MAD", 2, 100), - "MDL" to Currency("MDL", 2, 100), - "MGA" to Currency("MGA", 2, 100), - "MKD" to Currency("MKD", 2, 100), - "MMK" to Currency("MMK", 2, 100), - "MNT" to Currency("MNT", 2, 100), - "MOP" to Currency("MOP", 2, 100), - "MRU" to Currency("MRU", 2, 100), - "MUR" to Currency("MUR", 2, 100), - "MVR" to Currency("MVR", 2, 100), - "MWK" to Currency("MWK", 2, 100), - "MXN" to Currency("MXN", 2, 100), - "MXV" to Currency("MXV", 2, 100), - "MYR" to Currency("MYR", 2, 100), - "MZN" to Currency("MZN", 2, 100), - "NAD" to Currency("NAD", 2, 100), - "NGN" to Currency("NGN", 2, 100), - "NIO" to Currency("NIO", 2, 100), - "NOK" to Currency("NOK", 2, 100), - "NPR" to Currency("NPR", 2, 100), - "NZD" to Currency("NZD", 2, 100), - "OMR" to Currency("OMR", 3, 1000), - "PAB" to Currency("PAB", 2, 100), - "PEN" to Currency("PEN", 2, 100), - "PGK" to Currency("PGK", 2, 100), - "PHP" to Currency("PHP", 2, 100), - "PKR" to Currency("PKR", 2, 100), - "PLN" to Currency("PLN", 2, 100), - "PYG" to Currency("PYG", 0, 1), - "QAR" to Currency("QAR", 2, 100), - "RON" to Currency("RON", 2, 100), - "RSD" to Currency("RSD", 2, 100), - "RUB" to Currency("RUB", 2, 100), - "RWF" to Currency("RWF", 0, 1), - "SAR" to Currency("SAR", 2, 100), - "SBD" to Currency("SBD", 2, 100), - "SCR" to Currency("SCR", 2, 100), - "SDG" to Currency("SDG", 2, 100), - "SEK" to Currency("SEK", 2, 100), - "SGD" to Currency("SGD", 2, 100), - "SHP" to Currency("SHP", 2, 100), - "SLE" to Currency("SLE", 2, 100), - "SOS" to Currency("SOS", 2, 100), - "SRD" to Currency("SRD", 2, 100), - "SSP" to Currency("SSP", 2, 100), - "STN" to Currency("STN", 2, 100), - "SVC" to Currency("SVC", 2, 100), - "SYP" to Currency("SYP", 2, 100), - "SZL" to Currency("SZL", 2, 100), - "THB" to Currency("THB", 2, 100), - "TJS" to Currency("TJS", 2, 100), - "TMT" to Currency("TMT", 2, 100), - "TND" to Currency("TND", 3, 1000), - "TOP" to Currency("TOP", 2, 100), - "TRY" to Currency("TRY", 2, 100), - "TTD" to Currency("TTD", 2, 100), - "TWD" to Currency("TWD", 2, 100), - "TZS" to Currency("TZS", 2, 100), - "UAH" to Currency("UAH", 2, 100), - "UGX" to Currency("UGX", 0, 1), - "USD" to Currency("USD", 2, 100), - "USN" to Currency("USN", 2, 100), - "UYI" to Currency("UYI", 0, 1), - "UYU" to Currency("UYU", 2, 100), - "UYW" to Currency("UYW", 4, 10000), - "UZS" to Currency("UZS", 2, 100), - "VED" to Currency("VED", 2, 100), - "VES" to Currency("VES", 2, 100), - "VND" to Currency("VND", 0, 1), - "VUV" to Currency("VUV", 0, 1), - "WST" to Currency("WST", 2, 100), - "XAF" to Currency("XAF", 0, 1), - "XAG" to Currency("XAG", 0, 1), - "XAU" to Currency("XAU", 0, 1), - "XBA" to Currency("XBA", 0, 1), - "XBB" to Currency("XBB", 0, 1), - "XBC" to Currency("XBC", 0, 1), - "XBD" to Currency("XBD", 0, 1), - "XCD" to Currency("XCD", 2, 100), - "XDR" to Currency("XDR", 0, 1), - "XOF" to Currency("XOF", 0, 1), - "XPD" to Currency("XPD", 0, 1), - "XPF" to Currency("XPF", 0, 1), - "XPT" to Currency("XPT", 0, 1), - "XSU" to Currency("XSU", 0, 1), - "XTS" to Currency("XTS", 0, 1), - "XUA" to Currency("XUA", 0, 1), - "XXX" to Currency("XXX", 0, 1), - "YER" to Currency("YER", 2, 100), - "ZAR" to Currency("ZAR", 2, 100), - "ZMW" to Currency("ZMW", 2, 100), - "ZWG" to Currency("ZWG", 2, 100), - "ZWL" to Currency("ZWL", 2, 100) + "AED" to Currency("AED", 2, 100, "UAE Dirham"), + "AFN" to Currency("AFN", 2, 100, "Afghani"), + "ALL" to Currency("ALL", 2, 100, "Lek"), + "AMD" to Currency("AMD", 2, 100, "Armenian Dram"), + "ANG" to Currency("ANG", 2, 100, "Netherlands Antillean Guilder"), + "AOA" to Currency("AOA", 2, 100, "Kwanza"), + "ARS" to Currency("ARS", 2, 100, "Argentine Peso"), + "AUD" to Currency("AUD", 2, 100, "Australian Dollar"), + "AWG" to Currency("AWG", 2, 100, "Aruban Florin"), + "AZN" to Currency("AZN", 2, 100, "Azerbaijan Manat"), + "BAM" to Currency("BAM", 2, 100, "Convertible Mark"), + "BBD" to Currency("BBD", 2, 100, "Barbados Dollar"), + "BDT" to Currency("BDT", 2, 100, "Taka"), + "BGN" to Currency("BGN", 2, 100, "Bulgarian Lev"), + "BHD" to Currency("BHD", 3, 1000, "Bahraini Dinar"), + "BIF" to Currency("BIF", 0, 1, "Burundi Franc"), + "BMD" to Currency("BMD", 2, 100, "Bermudian Dollar"), + "BND" to Currency("BND", 2, 100, "Brunei Dollar"), + "BOB" to Currency("BOB", 2, 100, "Boliviano"), + "BOV" to Currency("BOV", 2, 100, "Mvdol"), + "BRL" to Currency("BRL", 2, 100, "Brazilian Real"), + "BSD" to Currency("BSD", 2, 100, "Bahamian Dollar"), + "BTN" to Currency("BTN", 2, 100, "Ngultrum"), + "BWP" to Currency("BWP", 2, 100, "Pula"), + "BYN" to Currency("BYN", 2, 100, "Belarusian Ruble"), + "BZD" to Currency("BZD", 2, 100, "Belize Dollar"), + "CAD" to Currency("CAD", 2, 100, "Canadian Dollar"), + "CDF" to Currency("CDF", 2, 100, "Congolese Franc"), + "CHE" to Currency("CHE", 2, 100, "WIR Euro"), + "CHF" to Currency("CHF", 2, 100, "Swiss Franc"), + "CHW" to Currency("CHW", 2, 100, "WIR Franc"), + "CLF" to Currency("CLF", 4, 10000, "Unidad de Fomento"), + "CLP" to Currency("CLP", 0, 1, "Chilean Peso"), + "CNY" to Currency("CNY", 2, 100, "Yuan Renminbi"), + "COP" to Currency("COP", 2, 100, "Colombian Peso"), + "COU" to Currency("COU", 2, 100, "Unidad de Valor Real"), + "CRC" to Currency("CRC", 2, 100, "Costa Rican Colon"), + "CUC" to Currency("CUC", 2, 100, "Peso Convertible"), + "CUP" to Currency("CUP", 2, 100, "Cuban Peso"), + "CVE" to Currency("CVE", 2, 100, "Cabo Verde Escudo"), + "CZK" to Currency("CZK", 2, 100, "Czech Koruna"), + "DJF" to Currency("DJF", 0, 1, "Djibouti Franc"), + "DKK" to Currency("DKK", 2, 100, "Danish Krone"), + "DOP" to Currency("DOP", 2, 100, "Dominican Peso"), + "DZD" to Currency("DZD", 2, 100, "Algerian Dinar"), + "EGP" to Currency("EGP", 2, 100, "Egyptian Pound"), + "ERN" to Currency("ERN", 2, 100, "Nakfa"), + "ETB" to Currency("ETB", 2, 100, "Ethiopian Birr"), + "EUR" to Currency("EUR", 2, 100, "Euro"), + "FJD" to Currency("FJD", 2, 100, "Fiji Dollar"), + "FKP" to Currency("FKP", 2, 100, "Falkland Islands Pound"), + "GBP" to Currency("GBP", 2, 100, "Pound Sterling"), + "GEL" to Currency("GEL", 2, 100, "Lari"), + "GHS" to Currency("GHS", 2, 100, "Ghana Cedi"), + "GIP" to Currency("GIP", 2, 100, "Gibraltar Pound"), + "GMD" to Currency("GMD", 2, 100, "Dalasi"), + "GNF" to Currency("GNF", 0, 1, "Guinean Franc"), + "GTQ" to Currency("GTQ", 2, 100, "Quetzal"), + "GYD" to Currency("GYD", 2, 100, "Guyana Dollar"), + "HKD" to Currency("HKD", 2, 100, "Hong Kong Dollar"), + "HNL" to Currency("HNL", 2, 100, "Lempira"), + "HTG" to Currency("HTG", 2, 100, "Gourde"), + "HUF" to Currency("HUF", 2, 100, "Forint"), + "IDR" to Currency("IDR", 2, 100, "Rupiah"), + "ILS" to Currency("ILS", 2, 100, "New Israeli Sheqel"), + "INR" to Currency("INR", 2, 100, "Indian Rupee"), + "IQD" to Currency("IQD", 3, 1000, "Iraqi Dinar"), + "IRR" to Currency("IRR", 2, 100, "Iranian Rial"), + "ISK" to Currency("ISK", 0, 1, "Iceland Krona"), + "JMD" to Currency("JMD", 2, 100, "Jamaican Dollar"), + "JOD" to Currency("JOD", 3, 1000, "Jordanian Dinar"), + "JPY" to Currency("JPY", 0, 1, "Yen"), + "KES" to Currency("KES", 2, 100, "Kenyan Shilling"), + "KGS" to Currency("KGS", 2, 100, "Som"), + "KHR" to Currency("KHR", 2, 100, "Riel"), + "KMF" to Currency("KMF", 0, 1, "Comorian Franc "), + "KPW" to Currency("KPW", 2, 100, "North Korean Won"), + "KRW" to Currency("KRW", 0, 1, "Won"), + "KWD" to Currency("KWD", 3, 1000, "Kuwaiti Dinar"), + "KYD" to Currency("KYD", 2, 100, "Cayman Islands Dollar"), + "KZT" to Currency("KZT", 2, 100, "Tenge"), + "LAK" to Currency("LAK", 2, 100, "Lao Kip"), + "LBP" to Currency("LBP", 2, 100, "Lebanese Pound"), + "LKR" to Currency("LKR", 2, 100, "Sri Lanka Rupee"), + "LRD" to Currency("LRD", 2, 100, "Liberian Dollar"), + "LSL" to Currency("LSL", 2, 100, "Loti"), + "LYD" to Currency("LYD", 3, 1000, "Libyan Dinar"), + "MAD" to Currency("MAD", 2, 100, "Moroccan Dirham"), + "MDL" to Currency("MDL", 2, 100, "Moldovan Leu"), + "MGA" to Currency("MGA", 2, 100, "Malagasy Ariary"), + "MKD" to Currency("MKD", 2, 100, "Denar"), + "MMK" to Currency("MMK", 2, 100, "Kyat"), + "MNT" to Currency("MNT", 2, 100, "Tugrik"), + "MOP" to Currency("MOP", 2, 100, "Pataca"), + "MRU" to Currency("MRU", 2, 100, "Ouguiya"), + "MUR" to Currency("MUR", 2, 100, "Mauritius Rupee"), + "MVR" to Currency("MVR", 2, 100, "Rufiyaa"), + "MWK" to Currency("MWK", 2, 100, "Malawi Kwacha"), + "MXN" to Currency("MXN", 2, 100, "Mexican Peso"), + "MXV" to Currency("MXV", 2, 100, "Mexican Unidad de Inversion (UDI)"), + "MYR" to Currency("MYR", 2, 100, "Malaysian Ringgit"), + "MZN" to Currency("MZN", 2, 100, "Mozambique Metical"), + "NAD" to Currency("NAD", 2, 100, "Namibia Dollar"), + "NGN" to Currency("NGN", 2, 100, "Naira"), + "NIO" to Currency("NIO", 2, 100, "Cordoba Oro"), + "NOK" to Currency("NOK", 2, 100, "Norwegian Krone"), + "NPR" to Currency("NPR", 2, 100, "Nepalese Rupee"), + "NZD" to Currency("NZD", 2, 100, "New Zealand Dollar"), + "OMR" to Currency("OMR", 3, 1000, "Rial Omani"), + "PAB" to Currency("PAB", 2, 100, "Balboa"), + "PEN" to Currency("PEN", 2, 100, "Sol"), + "PGK" to Currency("PGK", 2, 100, "Kina"), + "PHP" to Currency("PHP", 2, 100, "Philippine Peso"), + "PKR" to Currency("PKR", 2, 100, "Pakistan Rupee"), + "PLN" to Currency("PLN", 2, 100, "Zloty"), + "PYG" to Currency("PYG", 0, 1, "Guarani"), + "QAR" to Currency("QAR", 2, 100, "Qatari Rial"), + "RON" to Currency("RON", 2, 100, "Romanian Leu"), + "RSD" to Currency("RSD", 2, 100, "Serbian Dinar"), + "RUB" to Currency("RUB", 2, 100, "Russian Ruble"), + "RWF" to Currency("RWF", 0, 1, "Rwanda Franc"), + "SAR" to Currency("SAR", 2, 100, "Saudi Riyal"), + "SBD" to Currency("SBD", 2, 100, "Solomon Islands Dollar"), + "SCR" to Currency("SCR", 2, 100, "Seychelles Rupee"), + "SDG" to Currency("SDG", 2, 100, "Sudanese Pound"), + "SEK" to Currency("SEK", 2, 100, "Swedish Krona"), + "SGD" to Currency("SGD", 2, 100, "Singapore Dollar"), + "SHP" to Currency("SHP", 2, 100, "Saint Helena Pound"), + "SLE" to Currency("SLE", 2, 100, "Leone"), + "SOS" to Currency("SOS", 2, 100, "Somali Shilling"), + "SRD" to Currency("SRD", 2, 100, "Surinam Dollar"), + "SSP" to Currency("SSP", 2, 100, "South Sudanese Pound"), + "STN" to Currency("STN", 2, 100, "Dobra"), + "SVC" to Currency("SVC", 2, 100, "El Salvador Colon"), + "SYP" to Currency("SYP", 2, 100, "Syrian Pound"), + "SZL" to Currency("SZL", 2, 100, "Lilangeni"), + "THB" to Currency("THB", 2, 100, "Baht"), + "TJS" to Currency("TJS", 2, 100, "Somoni"), + "TMT" to Currency("TMT", 2, 100, "Turkmenistan New Manat"), + "TND" to Currency("TND", 3, 1000, "Tunisian Dinar"), + "TOP" to Currency("TOP", 2, 100, "Pa’anga"), + "TRY" to Currency("TRY", 2, 100, "Turkish Lira"), + "TTD" to Currency("TTD", 2, 100, "Trinidad and Tobago Dollar"), + "TWD" to Currency("TWD", 2, 100, "New Taiwan Dollar"), + "TZS" to Currency("TZS", 2, 100, "Tanzanian Shilling"), + "UAH" to Currency("UAH", 2, 100, "Hryvnia"), + "UGX" to Currency("UGX", 0, 1, "Uganda Shilling"), + "USD" to Currency("USD", 2, 100, "US Dollar"), + "USN" to Currency("USN", 2, 100, "US Dollar (Next day)"), + "UYI" to Currency("UYI", 0, 1, "Uruguay Peso en Unidades Indexadas (UI)"), + "UYU" to Currency("UYU", 2, 100, "Peso Uruguayo"), + "UYW" to Currency("UYW", 4, 10000, "Unidad Previsional"), + "UZS" to Currency("UZS", 2, 100, "Uzbekistan Sum"), + "VED" to Currency("VED", 2, 100, "Bolívar Soberano"), + "VES" to Currency("VES", 2, 100, "Bolívar Soberano"), + "VND" to Currency("VND", 0, 1, "Dong"), + "VUV" to Currency("VUV", 0, 1, "Vatu"), + "WST" to Currency("WST", 2, 100, "Tala"), + "XAF" to Currency("XAF", 0, 1, "CFA Franc BEAC"), + "XAG" to Currency("XAG", 0, 1, "Silver"), + "XAU" to Currency("XAU", 0, 1, "Gold"), + "XBA" to Currency("XBA", 0, 1, "Bond Markets Unit European Composite Unit (EURCO)"), + "XBB" to Currency("XBB", 0, 1, "Bond Markets Unit European Monetary Unit (E.M.U.-6)"), + "XBC" to Currency("XBC", 0, 1, "Bond Markets Unit European Unit of Account 9 (E.U.A.-9)"), + "XBD" to Currency("XBD", 0, 1, "Bond Markets Unit European Unit of Account 17 (E.U.A.-17)"), + "XCD" to Currency("XCD", 2, 100, "East Caribbean Dollar"), + "XDR" to Currency("XDR", 0, 1, "SDR (Special Drawing Right)"), + "XOF" to Currency("XOF", 0, 1, "CFA Franc BCEAO"), + "XPD" to Currency("XPD", 0, 1, "Palladium"), + "XPF" to Currency("XPF", 0, 1, "CFP Franc"), + "XPT" to Currency("XPT", 0, 1, "Platinum"), + "XSU" to Currency("XSU", 0, 1, "Sucre"), + "XTS" to Currency("XTS", 0, 1, "Codes specifically reserved for testing purposes"), + "XUA" to Currency("XUA", 0, 1, "ADB Unit of Account"), + "XXX" to Currency("XXX", 0, 1, "The codes assigned for transactions where no currency is involved"), + "YER" to Currency("YER", 2, 100, "Yemeni Rial"), + "ZAR" to Currency("ZAR", 2, 100, "Rand"), + "ZMW" to Currency("ZMW", 2, 100, "Zambian Kwacha"), + "ZWG" to Currency("ZWG", 2, 100, "Zimbabwe Gold"), + "ZWL" to Currency("ZWL", 2, 100, "Zimbabwe Dollar") ) } -} \ No newline at end of file +} diff --git a/std.swift b/std.swift index 052c15d..b83bc7c 100644 --- a/std.swift +++ b/std.swift @@ -9,189 +9,192 @@ struct Currency { /// The factor to divide the currency figure by before handing to a currency formatter var factor: Int + + /// The `ISO 4217` currency name + var name: String } class Currencies { - static let AED: Currency = Currency(code: "AED", minorUnits: 2, factor: 100) - static let AFN: Currency = Currency(code: "AFN", minorUnits: 2, factor: 100) - static let ALL: Currency = Currency(code: "ALL", minorUnits: 2, factor: 100) - static let AMD: Currency = Currency(code: "AMD", minorUnits: 2, factor: 100) - static let ANG: Currency = Currency(code: "ANG", minorUnits: 2, factor: 100) - static let AOA: Currency = Currency(code: "AOA", minorUnits: 2, factor: 100) - static let ARS: Currency = Currency(code: "ARS", minorUnits: 2, factor: 100) - static let AUD: Currency = Currency(code: "AUD", minorUnits: 2, factor: 100) - static let AWG: Currency = Currency(code: "AWG", minorUnits: 2, factor: 100) - static let AZN: Currency = Currency(code: "AZN", minorUnits: 2, factor: 100) - static let BAM: Currency = Currency(code: "BAM", minorUnits: 2, factor: 100) - static let BBD: Currency = Currency(code: "BBD", minorUnits: 2, factor: 100) - static let BDT: Currency = Currency(code: "BDT", minorUnits: 2, factor: 100) - static let BGN: Currency = Currency(code: "BGN", minorUnits: 2, factor: 100) - static let BHD: Currency = Currency(code: "BHD", minorUnits: 3, factor: 1000) - static let BIF: Currency = Currency(code: "BIF", minorUnits: 0, factor: 1) - static let BMD: Currency = Currency(code: "BMD", minorUnits: 2, factor: 100) - static let BND: Currency = Currency(code: "BND", minorUnits: 2, factor: 100) - static let BOB: Currency = Currency(code: "BOB", minorUnits: 2, factor: 100) - static let BOV: Currency = Currency(code: "BOV", minorUnits: 2, factor: 100) - static let BRL: Currency = Currency(code: "BRL", minorUnits: 2, factor: 100) - static let BSD: Currency = Currency(code: "BSD", minorUnits: 2, factor: 100) - static let BTN: Currency = Currency(code: "BTN", minorUnits: 2, factor: 100) - static let BWP: Currency = Currency(code: "BWP", minorUnits: 2, factor: 100) - static let BYN: Currency = Currency(code: "BYN", minorUnits: 2, factor: 100) - static let BZD: Currency = Currency(code: "BZD", minorUnits: 2, factor: 100) - static let CAD: Currency = Currency(code: "CAD", minorUnits: 2, factor: 100) - static let CDF: Currency = Currency(code: "CDF", minorUnits: 2, factor: 100) - static let CHE: Currency = Currency(code: "CHE", minorUnits: 2, factor: 100) - static let CHF: Currency = Currency(code: "CHF", minorUnits: 2, factor: 100) - static let CHW: Currency = Currency(code: "CHW", minorUnits: 2, factor: 100) - static let CLF: Currency = Currency(code: "CLF", minorUnits: 4, factor: 10000) - static let CLP: Currency = Currency(code: "CLP", minorUnits: 0, factor: 1) - static let CNY: Currency = Currency(code: "CNY", minorUnits: 2, factor: 100) - static let COP: Currency = Currency(code: "COP", minorUnits: 2, factor: 100) - static let COU: Currency = Currency(code: "COU", minorUnits: 2, factor: 100) - static let CRC: Currency = Currency(code: "CRC", minorUnits: 2, factor: 100) - static let CUC: Currency = Currency(code: "CUC", minorUnits: 2, factor: 100) - static let CUP: Currency = Currency(code: "CUP", minorUnits: 2, factor: 100) - static let CVE: Currency = Currency(code: "CVE", minorUnits: 2, factor: 100) - static let CZK: Currency = Currency(code: "CZK", minorUnits: 2, factor: 100) - static let DJF: Currency = Currency(code: "DJF", minorUnits: 0, factor: 1) - static let DKK: Currency = Currency(code: "DKK", minorUnits: 2, factor: 100) - static let DOP: Currency = Currency(code: "DOP", minorUnits: 2, factor: 100) - static let DZD: Currency = Currency(code: "DZD", minorUnits: 2, factor: 100) - static let EGP: Currency = Currency(code: "EGP", minorUnits: 2, factor: 100) - static let ERN: Currency = Currency(code: "ERN", minorUnits: 2, factor: 100) - static let ETB: Currency = Currency(code: "ETB", minorUnits: 2, factor: 100) - static let EUR: Currency = Currency(code: "EUR", minorUnits: 2, factor: 100) - static let FJD: Currency = Currency(code: "FJD", minorUnits: 2, factor: 100) - static let FKP: Currency = Currency(code: "FKP", minorUnits: 2, factor: 100) - static let GBP: Currency = Currency(code: "GBP", minorUnits: 2, factor: 100) - static let GEL: Currency = Currency(code: "GEL", minorUnits: 2, factor: 100) - static let GHS: Currency = Currency(code: "GHS", minorUnits: 2, factor: 100) - static let GIP: Currency = Currency(code: "GIP", minorUnits: 2, factor: 100) - static let GMD: Currency = Currency(code: "GMD", minorUnits: 2, factor: 100) - static let GNF: Currency = Currency(code: "GNF", minorUnits: 0, factor: 1) - static let GTQ: Currency = Currency(code: "GTQ", minorUnits: 2, factor: 100) - static let GYD: Currency = Currency(code: "GYD", minorUnits: 2, factor: 100) - static let HKD: Currency = Currency(code: "HKD", minorUnits: 2, factor: 100) - static let HNL: Currency = Currency(code: "HNL", minorUnits: 2, factor: 100) - static let HTG: Currency = Currency(code: "HTG", minorUnits: 2, factor: 100) - static let HUF: Currency = Currency(code: "HUF", minorUnits: 2, factor: 100) - static let IDR: Currency = Currency(code: "IDR", minorUnits: 2, factor: 100) - static let ILS: Currency = Currency(code: "ILS", minorUnits: 2, factor: 100) - static let INR: Currency = Currency(code: "INR", minorUnits: 2, factor: 100) - static let IQD: Currency = Currency(code: "IQD", minorUnits: 3, factor: 1000) - static let IRR: Currency = Currency(code: "IRR", minorUnits: 2, factor: 100) - static let ISK: Currency = Currency(code: "ISK", minorUnits: 0, factor: 1) - static let JMD: Currency = Currency(code: "JMD", minorUnits: 2, factor: 100) - static let JOD: Currency = Currency(code: "JOD", minorUnits: 3, factor: 1000) - static let JPY: Currency = Currency(code: "JPY", minorUnits: 0, factor: 1) - static let KES: Currency = Currency(code: "KES", minorUnits: 2, factor: 100) - static let KGS: Currency = Currency(code: "KGS", minorUnits: 2, factor: 100) - static let KHR: Currency = Currency(code: "KHR", minorUnits: 2, factor: 100) - static let KMF: Currency = Currency(code: "KMF", minorUnits: 0, factor: 1) - static let KPW: Currency = Currency(code: "KPW", minorUnits: 2, factor: 100) - static let KRW: Currency = Currency(code: "KRW", minorUnits: 0, factor: 1) - static let KWD: Currency = Currency(code: "KWD", minorUnits: 3, factor: 1000) - static let KYD: Currency = Currency(code: "KYD", minorUnits: 2, factor: 100) - static let KZT: Currency = Currency(code: "KZT", minorUnits: 2, factor: 100) - static let LAK: Currency = Currency(code: "LAK", minorUnits: 2, factor: 100) - static let LBP: Currency = Currency(code: "LBP", minorUnits: 2, factor: 100) - static let LKR: Currency = Currency(code: "LKR", minorUnits: 2, factor: 100) - static let LRD: Currency = Currency(code: "LRD", minorUnits: 2, factor: 100) - static let LSL: Currency = Currency(code: "LSL", minorUnits: 2, factor: 100) - static let LYD: Currency = Currency(code: "LYD", minorUnits: 3, factor: 1000) - static let MAD: Currency = Currency(code: "MAD", minorUnits: 2, factor: 100) - static let MDL: Currency = Currency(code: "MDL", minorUnits: 2, factor: 100) - static let MGA: Currency = Currency(code: "MGA", minorUnits: 2, factor: 100) - static let MKD: Currency = Currency(code: "MKD", minorUnits: 2, factor: 100) - static let MMK: Currency = Currency(code: "MMK", minorUnits: 2, factor: 100) - static let MNT: Currency = Currency(code: "MNT", minorUnits: 2, factor: 100) - static let MOP: Currency = Currency(code: "MOP", minorUnits: 2, factor: 100) - static let MRU: Currency = Currency(code: "MRU", minorUnits: 2, factor: 100) - static let MUR: Currency = Currency(code: "MUR", minorUnits: 2, factor: 100) - static let MVR: Currency = Currency(code: "MVR", minorUnits: 2, factor: 100) - static let MWK: Currency = Currency(code: "MWK", minorUnits: 2, factor: 100) - static let MXN: Currency = Currency(code: "MXN", minorUnits: 2, factor: 100) - static let MXV: Currency = Currency(code: "MXV", minorUnits: 2, factor: 100) - static let MYR: Currency = Currency(code: "MYR", minorUnits: 2, factor: 100) - static let MZN: Currency = Currency(code: "MZN", minorUnits: 2, factor: 100) - static let NAD: Currency = Currency(code: "NAD", minorUnits: 2, factor: 100) - static let NGN: Currency = Currency(code: "NGN", minorUnits: 2, factor: 100) - static let NIO: Currency = Currency(code: "NIO", minorUnits: 2, factor: 100) - static let NOK: Currency = Currency(code: "NOK", minorUnits: 2, factor: 100) - static let NPR: Currency = Currency(code: "NPR", minorUnits: 2, factor: 100) - static let NZD: Currency = Currency(code: "NZD", minorUnits: 2, factor: 100) - static let OMR: Currency = Currency(code: "OMR", minorUnits: 3, factor: 1000) - static let PAB: Currency = Currency(code: "PAB", minorUnits: 2, factor: 100) - static let PEN: Currency = Currency(code: "PEN", minorUnits: 2, factor: 100) - static let PGK: Currency = Currency(code: "PGK", minorUnits: 2, factor: 100) - static let PHP: Currency = Currency(code: "PHP", minorUnits: 2, factor: 100) - static let PKR: Currency = Currency(code: "PKR", minorUnits: 2, factor: 100) - static let PLN: Currency = Currency(code: "PLN", minorUnits: 2, factor: 100) - static let PYG: Currency = Currency(code: "PYG", minorUnits: 0, factor: 1) - static let QAR: Currency = Currency(code: "QAR", minorUnits: 2, factor: 100) - static let RON: Currency = Currency(code: "RON", minorUnits: 2, factor: 100) - static let RSD: Currency = Currency(code: "RSD", minorUnits: 2, factor: 100) - static let RUB: Currency = Currency(code: "RUB", minorUnits: 2, factor: 100) - static let RWF: Currency = Currency(code: "RWF", minorUnits: 0, factor: 1) - static let SAR: Currency = Currency(code: "SAR", minorUnits: 2, factor: 100) - static let SBD: Currency = Currency(code: "SBD", minorUnits: 2, factor: 100) - static let SCR: Currency = Currency(code: "SCR", minorUnits: 2, factor: 100) - static let SDG: Currency = Currency(code: "SDG", minorUnits: 2, factor: 100) - static let SEK: Currency = Currency(code: "SEK", minorUnits: 2, factor: 100) - static let SGD: Currency = Currency(code: "SGD", minorUnits: 2, factor: 100) - static let SHP: Currency = Currency(code: "SHP", minorUnits: 2, factor: 100) - static let SLE: Currency = Currency(code: "SLE", minorUnits: 2, factor: 100) - static let SOS: Currency = Currency(code: "SOS", minorUnits: 2, factor: 100) - static let SRD: Currency = Currency(code: "SRD", minorUnits: 2, factor: 100) - static let SSP: Currency = Currency(code: "SSP", minorUnits: 2, factor: 100) - static let STN: Currency = Currency(code: "STN", minorUnits: 2, factor: 100) - static let SVC: Currency = Currency(code: "SVC", minorUnits: 2, factor: 100) - static let SYP: Currency = Currency(code: "SYP", minorUnits: 2, factor: 100) - static let SZL: Currency = Currency(code: "SZL", minorUnits: 2, factor: 100) - static let THB: Currency = Currency(code: "THB", minorUnits: 2, factor: 100) - static let TJS: Currency = Currency(code: "TJS", minorUnits: 2, factor: 100) - static let TMT: Currency = Currency(code: "TMT", minorUnits: 2, factor: 100) - static let TND: Currency = Currency(code: "TND", minorUnits: 3, factor: 1000) - static let TOP: Currency = Currency(code: "TOP", minorUnits: 2, factor: 100) - static let TRY: Currency = Currency(code: "TRY", minorUnits: 2, factor: 100) - static let TTD: Currency = Currency(code: "TTD", minorUnits: 2, factor: 100) - static let TWD: Currency = Currency(code: "TWD", minorUnits: 2, factor: 100) - static let TZS: Currency = Currency(code: "TZS", minorUnits: 2, factor: 100) - static let UAH: Currency = Currency(code: "UAH", minorUnits: 2, factor: 100) - static let UGX: Currency = Currency(code: "UGX", minorUnits: 0, factor: 1) - static let USD: Currency = Currency(code: "USD", minorUnits: 2, factor: 100) - static let USN: Currency = Currency(code: "USN", minorUnits: 2, factor: 100) - static let UYI: Currency = Currency(code: "UYI", minorUnits: 0, factor: 1) - static let UYU: Currency = Currency(code: "UYU", minorUnits: 2, factor: 100) - static let UYW: Currency = Currency(code: "UYW", minorUnits: 4, factor: 10000) - static let UZS: Currency = Currency(code: "UZS", minorUnits: 2, factor: 100) - static let VED: Currency = Currency(code: "VED", minorUnits: 2, factor: 100) - static let VES: Currency = Currency(code: "VES", minorUnits: 2, factor: 100) - static let VND: Currency = Currency(code: "VND", minorUnits: 0, factor: 1) - static let VUV: Currency = Currency(code: "VUV", minorUnits: 0, factor: 1) - static let WST: Currency = Currency(code: "WST", minorUnits: 2, factor: 100) - static let XAF: Currency = Currency(code: "XAF", minorUnits: 0, factor: 1) - static let XAG: Currency = Currency(code: "XAG", minorUnits: 0, factor: 1) - static let XAU: Currency = Currency(code: "XAU", minorUnits: 0, factor: 1) - static let XBA: Currency = Currency(code: "XBA", minorUnits: 0, factor: 1) - static let XBB: Currency = Currency(code: "XBB", minorUnits: 0, factor: 1) - static let XBC: Currency = Currency(code: "XBC", minorUnits: 0, factor: 1) - static let XBD: Currency = Currency(code: "XBD", minorUnits: 0, factor: 1) - static let XCD: Currency = Currency(code: "XCD", minorUnits: 2, factor: 100) - static let XDR: Currency = Currency(code: "XDR", minorUnits: 0, factor: 1) - static let XOF: Currency = Currency(code: "XOF", minorUnits: 0, factor: 1) - static let XPD: Currency = Currency(code: "XPD", minorUnits: 0, factor: 1) - static let XPF: Currency = Currency(code: "XPF", minorUnits: 0, factor: 1) - static let XPT: Currency = Currency(code: "XPT", minorUnits: 0, factor: 1) - static let XSU: Currency = Currency(code: "XSU", minorUnits: 0, factor: 1) - static let XTS: Currency = Currency(code: "XTS", minorUnits: 0, factor: 1) - static let XUA: Currency = Currency(code: "XUA", minorUnits: 0, factor: 1) - static let XXX: Currency = Currency(code: "XXX", minorUnits: 0, factor: 1) - static let YER: Currency = Currency(code: "YER", minorUnits: 2, factor: 100) - static let ZAR: Currency = Currency(code: "ZAR", minorUnits: 2, factor: 100) - static let ZMW: Currency = Currency(code: "ZMW", minorUnits: 2, factor: 100) - static let ZWG: Currency = Currency(code: "ZWG", minorUnits: 2, factor: 100) - static let ZWL: Currency = Currency(code: "ZWL", minorUnits: 2, factor: 100) + static let AED: Currency = Currency(code: "AED", minorUnits: 2, factor: 100, name: "UAE Dirham") + static let AFN: Currency = Currency(code: "AFN", minorUnits: 2, factor: 100, name: "Afghani") + static let ALL: Currency = Currency(code: "ALL", minorUnits: 2, factor: 100, name: "Lek") + static let AMD: Currency = Currency(code: "AMD", minorUnits: 2, factor: 100, name: "Armenian Dram") + static let ANG: Currency = Currency(code: "ANG", minorUnits: 2, factor: 100, name: "Netherlands Antillean Guilder") + static let AOA: Currency = Currency(code: "AOA", minorUnits: 2, factor: 100, name: "Kwanza") + static let ARS: Currency = Currency(code: "ARS", minorUnits: 2, factor: 100, name: "Argentine Peso") + static let AUD: Currency = Currency(code: "AUD", minorUnits: 2, factor: 100, name: "Australian Dollar") + static let AWG: Currency = Currency(code: "AWG", minorUnits: 2, factor: 100, name: "Aruban Florin") + static let AZN: Currency = Currency(code: "AZN", minorUnits: 2, factor: 100, name: "Azerbaijan Manat") + static let BAM: Currency = Currency(code: "BAM", minorUnits: 2, factor: 100, name: "Convertible Mark") + static let BBD: Currency = Currency(code: "BBD", minorUnits: 2, factor: 100, name: "Barbados Dollar") + static let BDT: Currency = Currency(code: "BDT", minorUnits: 2, factor: 100, name: "Taka") + static let BGN: Currency = Currency(code: "BGN", minorUnits: 2, factor: 100, name: "Bulgarian Lev") + static let BHD: Currency = Currency(code: "BHD", minorUnits: 3, factor: 1000, name: "Bahraini Dinar") + static let BIF: Currency = Currency(code: "BIF", minorUnits: 0, factor: 1, name: "Burundi Franc") + static let BMD: Currency = Currency(code: "BMD", minorUnits: 2, factor: 100, name: "Bermudian Dollar") + static let BND: Currency = Currency(code: "BND", minorUnits: 2, factor: 100, name: "Brunei Dollar") + static let BOB: Currency = Currency(code: "BOB", minorUnits: 2, factor: 100, name: "Boliviano") + static let BOV: Currency = Currency(code: "BOV", minorUnits: 2, factor: 100, name: "Mvdol") + static let BRL: Currency = Currency(code: "BRL", minorUnits: 2, factor: 100, name: "Brazilian Real") + static let BSD: Currency = Currency(code: "BSD", minorUnits: 2, factor: 100, name: "Bahamian Dollar") + static let BTN: Currency = Currency(code: "BTN", minorUnits: 2, factor: 100, name: "Ngultrum") + static let BWP: Currency = Currency(code: "BWP", minorUnits: 2, factor: 100, name: "Pula") + static let BYN: Currency = Currency(code: "BYN", minorUnits: 2, factor: 100, name: "Belarusian Ruble") + static let BZD: Currency = Currency(code: "BZD", minorUnits: 2, factor: 100, name: "Belize Dollar") + static let CAD: Currency = Currency(code: "CAD", minorUnits: 2, factor: 100, name: "Canadian Dollar") + static let CDF: Currency = Currency(code: "CDF", minorUnits: 2, factor: 100, name: "Congolese Franc") + static let CHE: Currency = Currency(code: "CHE", minorUnits: 2, factor: 100, name: "WIR Euro") + static let CHF: Currency = Currency(code: "CHF", minorUnits: 2, factor: 100, name: "Swiss Franc") + static let CHW: Currency = Currency(code: "CHW", minorUnits: 2, factor: 100, name: "WIR Franc") + static let CLF: Currency = Currency(code: "CLF", minorUnits: 4, factor: 10000, name: "Unidad de Fomento") + static let CLP: Currency = Currency(code: "CLP", minorUnits: 0, factor: 1, name: "Chilean Peso") + static let CNY: Currency = Currency(code: "CNY", minorUnits: 2, factor: 100, name: "Yuan Renminbi") + static let COP: Currency = Currency(code: "COP", minorUnits: 2, factor: 100, name: "Colombian Peso") + static let COU: Currency = Currency(code: "COU", minorUnits: 2, factor: 100, name: "Unidad de Valor Real") + static let CRC: Currency = Currency(code: "CRC", minorUnits: 2, factor: 100, name: "Costa Rican Colon") + static let CUC: Currency = Currency(code: "CUC", minorUnits: 2, factor: 100, name: "Peso Convertible") + static let CUP: Currency = Currency(code: "CUP", minorUnits: 2, factor: 100, name: "Cuban Peso") + static let CVE: Currency = Currency(code: "CVE", minorUnits: 2, factor: 100, name: "Cabo Verde Escudo") + static let CZK: Currency = Currency(code: "CZK", minorUnits: 2, factor: 100, name: "Czech Koruna") + static let DJF: Currency = Currency(code: "DJF", minorUnits: 0, factor: 1, name: "Djibouti Franc") + static let DKK: Currency = Currency(code: "DKK", minorUnits: 2, factor: 100, name: "Danish Krone") + static let DOP: Currency = Currency(code: "DOP", minorUnits: 2, factor: 100, name: "Dominican Peso") + static let DZD: Currency = Currency(code: "DZD", minorUnits: 2, factor: 100, name: "Algerian Dinar") + static let EGP: Currency = Currency(code: "EGP", minorUnits: 2, factor: 100, name: "Egyptian Pound") + static let ERN: Currency = Currency(code: "ERN", minorUnits: 2, factor: 100, name: "Nakfa") + static let ETB: Currency = Currency(code: "ETB", minorUnits: 2, factor: 100, name: "Ethiopian Birr") + static let EUR: Currency = Currency(code: "EUR", minorUnits: 2, factor: 100, name: "Euro") + static let FJD: Currency = Currency(code: "FJD", minorUnits: 2, factor: 100, name: "Fiji Dollar") + static let FKP: Currency = Currency(code: "FKP", minorUnits: 2, factor: 100, name: "Falkland Islands Pound") + static let GBP: Currency = Currency(code: "GBP", minorUnits: 2, factor: 100, name: "Pound Sterling") + static let GEL: Currency = Currency(code: "GEL", minorUnits: 2, factor: 100, name: "Lari") + static let GHS: Currency = Currency(code: "GHS", minorUnits: 2, factor: 100, name: "Ghana Cedi") + static let GIP: Currency = Currency(code: "GIP", minorUnits: 2, factor: 100, name: "Gibraltar Pound") + static let GMD: Currency = Currency(code: "GMD", minorUnits: 2, factor: 100, name: "Dalasi") + static let GNF: Currency = Currency(code: "GNF", minorUnits: 0, factor: 1, name: "Guinean Franc") + static let GTQ: Currency = Currency(code: "GTQ", minorUnits: 2, factor: 100, name: "Quetzal") + static let GYD: Currency = Currency(code: "GYD", minorUnits: 2, factor: 100, name: "Guyana Dollar") + static let HKD: Currency = Currency(code: "HKD", minorUnits: 2, factor: 100, name: "Hong Kong Dollar") + static let HNL: Currency = Currency(code: "HNL", minorUnits: 2, factor: 100, name: "Lempira") + static let HTG: Currency = Currency(code: "HTG", minorUnits: 2, factor: 100, name: "Gourde") + static let HUF: Currency = Currency(code: "HUF", minorUnits: 2, factor: 100, name: "Forint") + static let IDR: Currency = Currency(code: "IDR", minorUnits: 2, factor: 100, name: "Rupiah") + static let ILS: Currency = Currency(code: "ILS", minorUnits: 2, factor: 100, name: "New Israeli Sheqel") + static let INR: Currency = Currency(code: "INR", minorUnits: 2, factor: 100, name: "Indian Rupee") + static let IQD: Currency = Currency(code: "IQD", minorUnits: 3, factor: 1000, name: "Iraqi Dinar") + static let IRR: Currency = Currency(code: "IRR", minorUnits: 2, factor: 100, name: "Iranian Rial") + static let ISK: Currency = Currency(code: "ISK", minorUnits: 0, factor: 1, name: "Iceland Krona") + static let JMD: Currency = Currency(code: "JMD", minorUnits: 2, factor: 100, name: "Jamaican Dollar") + static let JOD: Currency = Currency(code: "JOD", minorUnits: 3, factor: 1000, name: "Jordanian Dinar") + static let JPY: Currency = Currency(code: "JPY", minorUnits: 0, factor: 1, name: "Yen") + static let KES: Currency = Currency(code: "KES", minorUnits: 2, factor: 100, name: "Kenyan Shilling") + static let KGS: Currency = Currency(code: "KGS", minorUnits: 2, factor: 100, name: "Som") + static let KHR: Currency = Currency(code: "KHR", minorUnits: 2, factor: 100, name: "Riel") + static let KMF: Currency = Currency(code: "KMF", minorUnits: 0, factor: 1, name: "Comorian Franc ") + static let KPW: Currency = Currency(code: "KPW", minorUnits: 2, factor: 100, name: "North Korean Won") + static let KRW: Currency = Currency(code: "KRW", minorUnits: 0, factor: 1, name: "Won") + static let KWD: Currency = Currency(code: "KWD", minorUnits: 3, factor: 1000, name: "Kuwaiti Dinar") + static let KYD: Currency = Currency(code: "KYD", minorUnits: 2, factor: 100, name: "Cayman Islands Dollar") + static let KZT: Currency = Currency(code: "KZT", minorUnits: 2, factor: 100, name: "Tenge") + static let LAK: Currency = Currency(code: "LAK", minorUnits: 2, factor: 100, name: "Lao Kip") + static let LBP: Currency = Currency(code: "LBP", minorUnits: 2, factor: 100, name: "Lebanese Pound") + static let LKR: Currency = Currency(code: "LKR", minorUnits: 2, factor: 100, name: "Sri Lanka Rupee") + static let LRD: Currency = Currency(code: "LRD", minorUnits: 2, factor: 100, name: "Liberian Dollar") + static let LSL: Currency = Currency(code: "LSL", minorUnits: 2, factor: 100, name: "Loti") + static let LYD: Currency = Currency(code: "LYD", minorUnits: 3, factor: 1000, name: "Libyan Dinar") + static let MAD: Currency = Currency(code: "MAD", minorUnits: 2, factor: 100, name: "Moroccan Dirham") + static let MDL: Currency = Currency(code: "MDL", minorUnits: 2, factor: 100, name: "Moldovan Leu") + static let MGA: Currency = Currency(code: "MGA", minorUnits: 2, factor: 100, name: "Malagasy Ariary") + static let MKD: Currency = Currency(code: "MKD", minorUnits: 2, factor: 100, name: "Denar") + static let MMK: Currency = Currency(code: "MMK", minorUnits: 2, factor: 100, name: "Kyat") + static let MNT: Currency = Currency(code: "MNT", minorUnits: 2, factor: 100, name: "Tugrik") + static let MOP: Currency = Currency(code: "MOP", minorUnits: 2, factor: 100, name: "Pataca") + static let MRU: Currency = Currency(code: "MRU", minorUnits: 2, factor: 100, name: "Ouguiya") + static let MUR: Currency = Currency(code: "MUR", minorUnits: 2, factor: 100, name: "Mauritius Rupee") + static let MVR: Currency = Currency(code: "MVR", minorUnits: 2, factor: 100, name: "Rufiyaa") + static let MWK: Currency = Currency(code: "MWK", minorUnits: 2, factor: 100, name: "Malawi Kwacha") + static let MXN: Currency = Currency(code: "MXN", minorUnits: 2, factor: 100, name: "Mexican Peso") + static let MXV: Currency = Currency(code: "MXV", minorUnits: 2, factor: 100, name: "Mexican Unidad de Inversion (UDI)") + static let MYR: Currency = Currency(code: "MYR", minorUnits: 2, factor: 100, name: "Malaysian Ringgit") + static let MZN: Currency = Currency(code: "MZN", minorUnits: 2, factor: 100, name: "Mozambique Metical") + static let NAD: Currency = Currency(code: "NAD", minorUnits: 2, factor: 100, name: "Namibia Dollar") + static let NGN: Currency = Currency(code: "NGN", minorUnits: 2, factor: 100, name: "Naira") + static let NIO: Currency = Currency(code: "NIO", minorUnits: 2, factor: 100, name: "Cordoba Oro") + static let NOK: Currency = Currency(code: "NOK", minorUnits: 2, factor: 100, name: "Norwegian Krone") + static let NPR: Currency = Currency(code: "NPR", minorUnits: 2, factor: 100, name: "Nepalese Rupee") + static let NZD: Currency = Currency(code: "NZD", minorUnits: 2, factor: 100, name: "New Zealand Dollar") + static let OMR: Currency = Currency(code: "OMR", minorUnits: 3, factor: 1000, name: "Rial Omani") + static let PAB: Currency = Currency(code: "PAB", minorUnits: 2, factor: 100, name: "Balboa") + static let PEN: Currency = Currency(code: "PEN", minorUnits: 2, factor: 100, name: "Sol") + static let PGK: Currency = Currency(code: "PGK", minorUnits: 2, factor: 100, name: "Kina") + static let PHP: Currency = Currency(code: "PHP", minorUnits: 2, factor: 100, name: "Philippine Peso") + static let PKR: Currency = Currency(code: "PKR", minorUnits: 2, factor: 100, name: "Pakistan Rupee") + static let PLN: Currency = Currency(code: "PLN", minorUnits: 2, factor: 100, name: "Zloty") + static let PYG: Currency = Currency(code: "PYG", minorUnits: 0, factor: 1, name: "Guarani") + static let QAR: Currency = Currency(code: "QAR", minorUnits: 2, factor: 100, name: "Qatari Rial") + static let RON: Currency = Currency(code: "RON", minorUnits: 2, factor: 100, name: "Romanian Leu") + static let RSD: Currency = Currency(code: "RSD", minorUnits: 2, factor: 100, name: "Serbian Dinar") + static let RUB: Currency = Currency(code: "RUB", minorUnits: 2, factor: 100, name: "Russian Ruble") + static let RWF: Currency = Currency(code: "RWF", minorUnits: 0, factor: 1, name: "Rwanda Franc") + static let SAR: Currency = Currency(code: "SAR", minorUnits: 2, factor: 100, name: "Saudi Riyal") + static let SBD: Currency = Currency(code: "SBD", minorUnits: 2, factor: 100, name: "Solomon Islands Dollar") + static let SCR: Currency = Currency(code: "SCR", minorUnits: 2, factor: 100, name: "Seychelles Rupee") + static let SDG: Currency = Currency(code: "SDG", minorUnits: 2, factor: 100, name: "Sudanese Pound") + static let SEK: Currency = Currency(code: "SEK", minorUnits: 2, factor: 100, name: "Swedish Krona") + static let SGD: Currency = Currency(code: "SGD", minorUnits: 2, factor: 100, name: "Singapore Dollar") + static let SHP: Currency = Currency(code: "SHP", minorUnits: 2, factor: 100, name: "Saint Helena Pound") + static let SLE: Currency = Currency(code: "SLE", minorUnits: 2, factor: 100, name: "Leone") + static let SOS: Currency = Currency(code: "SOS", minorUnits: 2, factor: 100, name: "Somali Shilling") + static let SRD: Currency = Currency(code: "SRD", minorUnits: 2, factor: 100, name: "Surinam Dollar") + static let SSP: Currency = Currency(code: "SSP", minorUnits: 2, factor: 100, name: "South Sudanese Pound") + static let STN: Currency = Currency(code: "STN", minorUnits: 2, factor: 100, name: "Dobra") + static let SVC: Currency = Currency(code: "SVC", minorUnits: 2, factor: 100, name: "El Salvador Colon") + static let SYP: Currency = Currency(code: "SYP", minorUnits: 2, factor: 100, name: "Syrian Pound") + static let SZL: Currency = Currency(code: "SZL", minorUnits: 2, factor: 100, name: "Lilangeni") + static let THB: Currency = Currency(code: "THB", minorUnits: 2, factor: 100, name: "Baht") + static let TJS: Currency = Currency(code: "TJS", minorUnits: 2, factor: 100, name: "Somoni") + static let TMT: Currency = Currency(code: "TMT", minorUnits: 2, factor: 100, name: "Turkmenistan New Manat") + static let TND: Currency = Currency(code: "TND", minorUnits: 3, factor: 1000, name: "Tunisian Dinar") + static let TOP: Currency = Currency(code: "TOP", minorUnits: 2, factor: 100, name: "Pa’anga") + static let TRY: Currency = Currency(code: "TRY", minorUnits: 2, factor: 100, name: "Turkish Lira") + static let TTD: Currency = Currency(code: "TTD", minorUnits: 2, factor: 100, name: "Trinidad and Tobago Dollar") + static let TWD: Currency = Currency(code: "TWD", minorUnits: 2, factor: 100, name: "New Taiwan Dollar") + static let TZS: Currency = Currency(code: "TZS", minorUnits: 2, factor: 100, name: "Tanzanian Shilling") + static let UAH: Currency = Currency(code: "UAH", minorUnits: 2, factor: 100, name: "Hryvnia") + static let UGX: Currency = Currency(code: "UGX", minorUnits: 0, factor: 1, name: "Uganda Shilling") + static let USD: Currency = Currency(code: "USD", minorUnits: 2, factor: 100, name: "US Dollar") + static let USN: Currency = Currency(code: "USN", minorUnits: 2, factor: 100, name: "US Dollar (Next day)") + static let UYI: Currency = Currency(code: "UYI", minorUnits: 0, factor: 1, name: "Uruguay Peso en Unidades Indexadas (UI)") + static let UYU: Currency = Currency(code: "UYU", minorUnits: 2, factor: 100, name: "Peso Uruguayo") + static let UYW: Currency = Currency(code: "UYW", minorUnits: 4, factor: 10000, name: "Unidad Previsional") + static let UZS: Currency = Currency(code: "UZS", minorUnits: 2, factor: 100, name: "Uzbekistan Sum") + static let VED: Currency = Currency(code: "VED", minorUnits: 2, factor: 100, name: "Bolívar Soberano") + static let VES: Currency = Currency(code: "VES", minorUnits: 2, factor: 100, name: "Bolívar Soberano") + static let VND: Currency = Currency(code: "VND", minorUnits: 0, factor: 1, name: "Dong") + static let VUV: Currency = Currency(code: "VUV", minorUnits: 0, factor: 1, name: "Vatu") + static let WST: Currency = Currency(code: "WST", minorUnits: 2, factor: 100, name: "Tala") + static let XAF: Currency = Currency(code: "XAF", minorUnits: 0, factor: 1, name: "CFA Franc BEAC") + static let XAG: Currency = Currency(code: "XAG", minorUnits: 0, factor: 1, name: "Silver") + static let XAU: Currency = Currency(code: "XAU", minorUnits: 0, factor: 1, name: "Gold") + static let XBA: Currency = Currency(code: "XBA", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Composite Unit (EURCO)") + static let XBB: Currency = Currency(code: "XBB", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Monetary Unit (E.M.U.-6)") + static let XBC: Currency = Currency(code: "XBC", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Unit of Account 9 (E.U.A.-9)") + static let XBD: Currency = Currency(code: "XBD", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Unit of Account 17 (E.U.A.-17)") + static let XCD: Currency = Currency(code: "XCD", minorUnits: 2, factor: 100, name: "East Caribbean Dollar") + static let XDR: Currency = Currency(code: "XDR", minorUnits: 0, factor: 1, name: "SDR (Special Drawing Right)") + static let XOF: Currency = Currency(code: "XOF", minorUnits: 0, factor: 1, name: "CFA Franc BCEAO") + static let XPD: Currency = Currency(code: "XPD", minorUnits: 0, factor: 1, name: "Palladium") + static let XPF: Currency = Currency(code: "XPF", minorUnits: 0, factor: 1, name: "CFP Franc") + static let XPT: Currency = Currency(code: "XPT", minorUnits: 0, factor: 1, name: "Platinum") + static let XSU: Currency = Currency(code: "XSU", minorUnits: 0, factor: 1, name: "Sucre") + static let XTS: Currency = Currency(code: "XTS", minorUnits: 0, factor: 1, name: "Codes specifically reserved for testing purposes") + static let XUA: Currency = Currency(code: "XUA", minorUnits: 0, factor: 1, name: "ADB Unit of Account") + static let XXX: Currency = Currency(code: "XXX", minorUnits: 0, factor: 1, name: "The codes assigned for transactions where no currency is involved") + static let YER: Currency = Currency(code: "YER", minorUnits: 2, factor: 100, name: "Yemeni Rial") + static let ZAR: Currency = Currency(code: "ZAR", minorUnits: 2, factor: 100, name: "Rand") + static let ZMW: Currency = Currency(code: "ZMW", minorUnits: 2, factor: 100, name: "Zambian Kwacha") + static let ZWG: Currency = Currency(code: "ZWG", minorUnits: 2, factor: 100, name: "Zimbabwe Gold") + static let ZWL: Currency = Currency(code: "ZWL", minorUnits: 2, factor: 100, name: "Zimbabwe Dollar") static let allCurrencies: [String: Currency] = diff --git a/std_currency.js b/std_currency.js index a8c05f9..7845489 100644 --- a/std_currency.js +++ b/std_currency.js @@ -1,362 +1,362 @@ var stdCurrency = { // AED currency object - AED: { code: "AED", name: "UAE Dirham", minorUnits: 2, factor: 100}, + AED: { code: "AED", name: "UAE Dirham", minorUnits: 2, factor: 100, name: "UAE Dirham"}, // AFN currency object - AFN: { code: "AFN", name: "Afghani", minorUnits: 2, factor: 100}, + AFN: { code: "AFN", name: "Afghani", minorUnits: 2, factor: 100, name: "Afghani"}, // ALL currency object - ALL: { code: "ALL", name: "Lek", minorUnits: 2, factor: 100}, + ALL: { code: "ALL", name: "Lek", minorUnits: 2, factor: 100, name: "Lek"}, // AMD currency object - AMD: { code: "AMD", name: "Armenian Dram", minorUnits: 2, factor: 100}, + AMD: { code: "AMD", name: "Armenian Dram", minorUnits: 2, factor: 100, name: "Armenian Dram"}, // ANG currency object - ANG: { code: "ANG", name: "Netherlands Antillean Guilder", minorUnits: 2, factor: 100}, + ANG: { code: "ANG", name: "Netherlands Antillean Guilder", minorUnits: 2, factor: 100, name: "Netherlands Antillean Guilder"}, // AOA currency object - AOA: { code: "AOA", name: "Kwanza", minorUnits: 2, factor: 100}, + AOA: { code: "AOA", name: "Kwanza", minorUnits: 2, factor: 100, name: "Kwanza"}, // ARS currency object - ARS: { code: "ARS", name: "Argentine Peso", minorUnits: 2, factor: 100}, + ARS: { code: "ARS", name: "Argentine Peso", minorUnits: 2, factor: 100, name: "Argentine Peso"}, // AUD currency object - AUD: { code: "AUD", name: "Australian Dollar", minorUnits: 2, factor: 100}, + AUD: { code: "AUD", name: "Australian Dollar", minorUnits: 2, factor: 100, name: "Australian Dollar"}, // AWG currency object - AWG: { code: "AWG", name: "Aruban Florin", minorUnits: 2, factor: 100}, + AWG: { code: "AWG", name: "Aruban Florin", minorUnits: 2, factor: 100, name: "Aruban Florin"}, // AZN currency object - AZN: { code: "AZN", name: "Azerbaijan Manat", minorUnits: 2, factor: 100}, + AZN: { code: "AZN", name: "Azerbaijan Manat", minorUnits: 2, factor: 100, name: "Azerbaijan Manat"}, // BAM currency object - BAM: { code: "BAM", name: "Convertible Mark", minorUnits: 2, factor: 100}, + BAM: { code: "BAM", name: "Convertible Mark", minorUnits: 2, factor: 100, name: "Convertible Mark"}, // BBD currency object - BBD: { code: "BBD", name: "Barbados Dollar", minorUnits: 2, factor: 100}, + BBD: { code: "BBD", name: "Barbados Dollar", minorUnits: 2, factor: 100, name: "Barbados Dollar"}, // BDT currency object - BDT: { code: "BDT", name: "Taka", minorUnits: 2, factor: 100}, + BDT: { code: "BDT", name: "Taka", minorUnits: 2, factor: 100, name: "Taka"}, // BGN currency object - BGN: { code: "BGN", name: "Bulgarian Lev", minorUnits: 2, factor: 100}, + BGN: { code: "BGN", name: "Bulgarian Lev", minorUnits: 2, factor: 100, name: "Bulgarian Lev"}, // BHD currency object - BHD: { code: "BHD", name: "Bahraini Dinar", minorUnits: 3, factor: 1000}, + BHD: { code: "BHD", name: "Bahraini Dinar", minorUnits: 3, factor: 1000, name: "Bahraini Dinar"}, // BIF currency object - BIF: { code: "BIF", name: "Burundi Franc", minorUnits: 0, factor: 1}, + BIF: { code: "BIF", name: "Burundi Franc", minorUnits: 0, factor: 1, name: "Burundi Franc"}, // BMD currency object - BMD: { code: "BMD", name: "Bermudian Dollar", minorUnits: 2, factor: 100}, + BMD: { code: "BMD", name: "Bermudian Dollar", minorUnits: 2, factor: 100, name: "Bermudian Dollar"}, // BND currency object - BND: { code: "BND", name: "Brunei Dollar", minorUnits: 2, factor: 100}, + BND: { code: "BND", name: "Brunei Dollar", minorUnits: 2, factor: 100, name: "Brunei Dollar"}, // BOB currency object - BOB: { code: "BOB", name: "Boliviano", minorUnits: 2, factor: 100}, + BOB: { code: "BOB", name: "Boliviano", minorUnits: 2, factor: 100, name: "Boliviano"}, // BOV currency object - BOV: { code: "BOV", name: "Mvdol", minorUnits: 2, factor: 100}, + BOV: { code: "BOV", name: "Mvdol", minorUnits: 2, factor: 100, name: "Mvdol"}, // BRL currency object - BRL: { code: "BRL", name: "Brazilian Real", minorUnits: 2, factor: 100}, + BRL: { code: "BRL", name: "Brazilian Real", minorUnits: 2, factor: 100, name: "Brazilian Real"}, // BSD currency object - BSD: { code: "BSD", name: "Bahamian Dollar", minorUnits: 2, factor: 100}, + BSD: { code: "BSD", name: "Bahamian Dollar", minorUnits: 2, factor: 100, name: "Bahamian Dollar"}, // BTN currency object - BTN: { code: "BTN", name: "Ngultrum", minorUnits: 2, factor: 100}, + BTN: { code: "BTN", name: "Ngultrum", minorUnits: 2, factor: 100, name: "Ngultrum"}, // BWP currency object - BWP: { code: "BWP", name: "Pula", minorUnits: 2, factor: 100}, + BWP: { code: "BWP", name: "Pula", minorUnits: 2, factor: 100, name: "Pula"}, // BYN currency object - BYN: { code: "BYN", name: "Belarusian Ruble", minorUnits: 2, factor: 100}, + BYN: { code: "BYN", name: "Belarusian Ruble", minorUnits: 2, factor: 100, name: "Belarusian Ruble"}, // BZD currency object - BZD: { code: "BZD", name: "Belize Dollar", minorUnits: 2, factor: 100}, + BZD: { code: "BZD", name: "Belize Dollar", minorUnits: 2, factor: 100, name: "Belize Dollar"}, // CAD currency object - CAD: { code: "CAD", name: "Canadian Dollar", minorUnits: 2, factor: 100}, + CAD: { code: "CAD", name: "Canadian Dollar", minorUnits: 2, factor: 100, name: "Canadian Dollar"}, // CDF currency object - CDF: { code: "CDF", name: "Congolese Franc", minorUnits: 2, factor: 100}, + CDF: { code: "CDF", name: "Congolese Franc", minorUnits: 2, factor: 100, name: "Congolese Franc"}, // CHE currency object - CHE: { code: "CHE", name: "WIR Euro", minorUnits: 2, factor: 100}, + CHE: { code: "CHE", name: "WIR Euro", minorUnits: 2, factor: 100, name: "WIR Euro"}, // CHF currency object - CHF: { code: "CHF", name: "Swiss Franc", minorUnits: 2, factor: 100}, + CHF: { code: "CHF", name: "Swiss Franc", minorUnits: 2, factor: 100, name: "Swiss Franc"}, // CHW currency object - CHW: { code: "CHW", name: "WIR Franc", minorUnits: 2, factor: 100}, + CHW: { code: "CHW", name: "WIR Franc", minorUnits: 2, factor: 100, name: "WIR Franc"}, // CLF currency object - CLF: { code: "CLF", name: "Unidad de Fomento", minorUnits: 4, factor: 10000}, + CLF: { code: "CLF", name: "Unidad de Fomento", minorUnits: 4, factor: 10000, name: "Unidad de Fomento"}, // CLP currency object - CLP: { code: "CLP", name: "Chilean Peso", minorUnits: 0, factor: 1}, + CLP: { code: "CLP", name: "Chilean Peso", minorUnits: 0, factor: 1, name: "Chilean Peso"}, // CNY currency object - CNY: { code: "CNY", name: "Yuan Renminbi", minorUnits: 2, factor: 100}, + CNY: { code: "CNY", name: "Yuan Renminbi", minorUnits: 2, factor: 100, name: "Yuan Renminbi"}, // COP currency object - COP: { code: "COP", name: "Colombian Peso", minorUnits: 2, factor: 100}, + COP: { code: "COP", name: "Colombian Peso", minorUnits: 2, factor: 100, name: "Colombian Peso"}, // COU currency object - COU: { code: "COU", name: "Unidad de Valor Real", minorUnits: 2, factor: 100}, + COU: { code: "COU", name: "Unidad de Valor Real", minorUnits: 2, factor: 100, name: "Unidad de Valor Real"}, // CRC currency object - CRC: { code: "CRC", name: "Costa Rican Colon", minorUnits: 2, factor: 100}, + CRC: { code: "CRC", name: "Costa Rican Colon", minorUnits: 2, factor: 100, name: "Costa Rican Colon"}, // CUC currency object - CUC: { code: "CUC", name: "Peso Convertible", minorUnits: 2, factor: 100}, + CUC: { code: "CUC", name: "Peso Convertible", minorUnits: 2, factor: 100, name: "Peso Convertible"}, // CUP currency object - CUP: { code: "CUP", name: "Cuban Peso", minorUnits: 2, factor: 100}, + CUP: { code: "CUP", name: "Cuban Peso", minorUnits: 2, factor: 100, name: "Cuban Peso"}, // CVE currency object - CVE: { code: "CVE", name: "Cabo Verde Escudo", minorUnits: 2, factor: 100}, + CVE: { code: "CVE", name: "Cabo Verde Escudo", minorUnits: 2, factor: 100, name: "Cabo Verde Escudo"}, // CZK currency object - CZK: { code: "CZK", name: "Czech Koruna", minorUnits: 2, factor: 100}, + CZK: { code: "CZK", name: "Czech Koruna", minorUnits: 2, factor: 100, name: "Czech Koruna"}, // DJF currency object - DJF: { code: "DJF", name: "Djibouti Franc", minorUnits: 0, factor: 1}, + DJF: { code: "DJF", name: "Djibouti Franc", minorUnits: 0, factor: 1, name: "Djibouti Franc"}, // DKK currency object - DKK: { code: "DKK", name: "Danish Krone", minorUnits: 2, factor: 100}, + DKK: { code: "DKK", name: "Danish Krone", minorUnits: 2, factor: 100, name: "Danish Krone"}, // DOP currency object - DOP: { code: "DOP", name: "Dominican Peso", minorUnits: 2, factor: 100}, + DOP: { code: "DOP", name: "Dominican Peso", minorUnits: 2, factor: 100, name: "Dominican Peso"}, // DZD currency object - DZD: { code: "DZD", name: "Algerian Dinar", minorUnits: 2, factor: 100}, + DZD: { code: "DZD", name: "Algerian Dinar", minorUnits: 2, factor: 100, name: "Algerian Dinar"}, // EGP currency object - EGP: { code: "EGP", name: "Egyptian Pound", minorUnits: 2, factor: 100}, + EGP: { code: "EGP", name: "Egyptian Pound", minorUnits: 2, factor: 100, name: "Egyptian Pound"}, // ERN currency object - ERN: { code: "ERN", name: "Nakfa", minorUnits: 2, factor: 100}, + ERN: { code: "ERN", name: "Nakfa", minorUnits: 2, factor: 100, name: "Nakfa"}, // ETB currency object - ETB: { code: "ETB", name: "Ethiopian Birr", minorUnits: 2, factor: 100}, + ETB: { code: "ETB", name: "Ethiopian Birr", minorUnits: 2, factor: 100, name: "Ethiopian Birr"}, // EUR currency object - EUR: { code: "EUR", name: "Euro", minorUnits: 2, factor: 100}, + EUR: { code: "EUR", name: "Euro", minorUnits: 2, factor: 100, name: "Euro"}, // FJD currency object - FJD: { code: "FJD", name: "Fiji Dollar", minorUnits: 2, factor: 100}, + FJD: { code: "FJD", name: "Fiji Dollar", minorUnits: 2, factor: 100, name: "Fiji Dollar"}, // FKP currency object - FKP: { code: "FKP", name: "Falkland Islands Pound", minorUnits: 2, factor: 100}, + FKP: { code: "FKP", name: "Falkland Islands Pound", minorUnits: 2, factor: 100, name: "Falkland Islands Pound"}, // GBP currency object - GBP: { code: "GBP", name: "Pound Sterling", minorUnits: 2, factor: 100}, + GBP: { code: "GBP", name: "Pound Sterling", minorUnits: 2, factor: 100, name: "Pound Sterling"}, // GEL currency object - GEL: { code: "GEL", name: "Lari", minorUnits: 2, factor: 100}, + GEL: { code: "GEL", name: "Lari", minorUnits: 2, factor: 100, name: "Lari"}, // GHS currency object - GHS: { code: "GHS", name: "Ghana Cedi", minorUnits: 2, factor: 100}, + GHS: { code: "GHS", name: "Ghana Cedi", minorUnits: 2, factor: 100, name: "Ghana Cedi"}, // GIP currency object - GIP: { code: "GIP", name: "Gibraltar Pound", minorUnits: 2, factor: 100}, + GIP: { code: "GIP", name: "Gibraltar Pound", minorUnits: 2, factor: 100, name: "Gibraltar Pound"}, // GMD currency object - GMD: { code: "GMD", name: "Dalasi", minorUnits: 2, factor: 100}, + GMD: { code: "GMD", name: "Dalasi", minorUnits: 2, factor: 100, name: "Dalasi"}, // GNF currency object - GNF: { code: "GNF", name: "Guinean Franc", minorUnits: 0, factor: 1}, + GNF: { code: "GNF", name: "Guinean Franc", minorUnits: 0, factor: 1, name: "Guinean Franc"}, // GTQ currency object - GTQ: { code: "GTQ", name: "Quetzal", minorUnits: 2, factor: 100}, + GTQ: { code: "GTQ", name: "Quetzal", minorUnits: 2, factor: 100, name: "Quetzal"}, // GYD currency object - GYD: { code: "GYD", name: "Guyana Dollar", minorUnits: 2, factor: 100}, + GYD: { code: "GYD", name: "Guyana Dollar", minorUnits: 2, factor: 100, name: "Guyana Dollar"}, // HKD currency object - HKD: { code: "HKD", name: "Hong Kong Dollar", minorUnits: 2, factor: 100}, + HKD: { code: "HKD", name: "Hong Kong Dollar", minorUnits: 2, factor: 100, name: "Hong Kong Dollar"}, // HNL currency object - HNL: { code: "HNL", name: "Lempira", minorUnits: 2, factor: 100}, + HNL: { code: "HNL", name: "Lempira", minorUnits: 2, factor: 100, name: "Lempira"}, // HTG currency object - HTG: { code: "HTG", name: "Gourde", minorUnits: 2, factor: 100}, + HTG: { code: "HTG", name: "Gourde", minorUnits: 2, factor: 100, name: "Gourde"}, // HUF currency object - HUF: { code: "HUF", name: "Forint", minorUnits: 2, factor: 100}, + HUF: { code: "HUF", name: "Forint", minorUnits: 2, factor: 100, name: "Forint"}, // IDR currency object - IDR: { code: "IDR", name: "Rupiah", minorUnits: 2, factor: 100}, + IDR: { code: "IDR", name: "Rupiah", minorUnits: 2, factor: 100, name: "Rupiah"}, // ILS currency object - ILS: { code: "ILS", name: "New Israeli Sheqel", minorUnits: 2, factor: 100}, + ILS: { code: "ILS", name: "New Israeli Sheqel", minorUnits: 2, factor: 100, name: "New Israeli Sheqel"}, // INR currency object - INR: { code: "INR", name: "Indian Rupee", minorUnits: 2, factor: 100}, + INR: { code: "INR", name: "Indian Rupee", minorUnits: 2, factor: 100, name: "Indian Rupee"}, // IQD currency object - IQD: { code: "IQD", name: "Iraqi Dinar", minorUnits: 3, factor: 1000}, + IQD: { code: "IQD", name: "Iraqi Dinar", minorUnits: 3, factor: 1000, name: "Iraqi Dinar"}, // IRR currency object - IRR: { code: "IRR", name: "Iranian Rial", minorUnits: 2, factor: 100}, + IRR: { code: "IRR", name: "Iranian Rial", minorUnits: 2, factor: 100, name: "Iranian Rial"}, // ISK currency object - ISK: { code: "ISK", name: "Iceland Krona", minorUnits: 0, factor: 1}, + ISK: { code: "ISK", name: "Iceland Krona", minorUnits: 0, factor: 1, name: "Iceland Krona"}, // JMD currency object - JMD: { code: "JMD", name: "Jamaican Dollar", minorUnits: 2, factor: 100}, + JMD: { code: "JMD", name: "Jamaican Dollar", minorUnits: 2, factor: 100, name: "Jamaican Dollar"}, // JOD currency object - JOD: { code: "JOD", name: "Jordanian Dinar", minorUnits: 3, factor: 1000}, + JOD: { code: "JOD", name: "Jordanian Dinar", minorUnits: 3, factor: 1000, name: "Jordanian Dinar"}, // JPY currency object - JPY: { code: "JPY", name: "Yen", minorUnits: 0, factor: 1}, + JPY: { code: "JPY", name: "Yen", minorUnits: 0, factor: 1, name: "Yen"}, // KES currency object - KES: { code: "KES", name: "Kenyan Shilling", minorUnits: 2, factor: 100}, + KES: { code: "KES", name: "Kenyan Shilling", minorUnits: 2, factor: 100, name: "Kenyan Shilling"}, // KGS currency object - KGS: { code: "KGS", name: "Som", minorUnits: 2, factor: 100}, + KGS: { code: "KGS", name: "Som", minorUnits: 2, factor: 100, name: "Som"}, // KHR currency object - KHR: { code: "KHR", name: "Riel", minorUnits: 2, factor: 100}, + KHR: { code: "KHR", name: "Riel", minorUnits: 2, factor: 100, name: "Riel"}, // KMF currency object - KMF: { code: "KMF", name: "Comorian Franc ", minorUnits: 0, factor: 1}, + KMF: { code: "KMF", name: "Comorian Franc ", minorUnits: 0, factor: 1, name: "Comorian Franc "}, // KPW currency object - KPW: { code: "KPW", name: "North Korean Won", minorUnits: 2, factor: 100}, + KPW: { code: "KPW", name: "North Korean Won", minorUnits: 2, factor: 100, name: "North Korean Won"}, // KRW currency object - KRW: { code: "KRW", name: "Won", minorUnits: 0, factor: 1}, + KRW: { code: "KRW", name: "Won", minorUnits: 0, factor: 1, name: "Won"}, // KWD currency object - KWD: { code: "KWD", name: "Kuwaiti Dinar", minorUnits: 3, factor: 1000}, + KWD: { code: "KWD", name: "Kuwaiti Dinar", minorUnits: 3, factor: 1000, name: "Kuwaiti Dinar"}, // KYD currency object - KYD: { code: "KYD", name: "Cayman Islands Dollar", minorUnits: 2, factor: 100}, + KYD: { code: "KYD", name: "Cayman Islands Dollar", minorUnits: 2, factor: 100, name: "Cayman Islands Dollar"}, // KZT currency object - KZT: { code: "KZT", name: "Tenge", minorUnits: 2, factor: 100}, + KZT: { code: "KZT", name: "Tenge", minorUnits: 2, factor: 100, name: "Tenge"}, // LAK currency object - LAK: { code: "LAK", name: "Lao Kip", minorUnits: 2, factor: 100}, + LAK: { code: "LAK", name: "Lao Kip", minorUnits: 2, factor: 100, name: "Lao Kip"}, // LBP currency object - LBP: { code: "LBP", name: "Lebanese Pound", minorUnits: 2, factor: 100}, + LBP: { code: "LBP", name: "Lebanese Pound", minorUnits: 2, factor: 100, name: "Lebanese Pound"}, // LKR currency object - LKR: { code: "LKR", name: "Sri Lanka Rupee", minorUnits: 2, factor: 100}, + LKR: { code: "LKR", name: "Sri Lanka Rupee", minorUnits: 2, factor: 100, name: "Sri Lanka Rupee"}, // LRD currency object - LRD: { code: "LRD", name: "Liberian Dollar", minorUnits: 2, factor: 100}, + LRD: { code: "LRD", name: "Liberian Dollar", minorUnits: 2, factor: 100, name: "Liberian Dollar"}, // LSL currency object - LSL: { code: "LSL", name: "Loti", minorUnits: 2, factor: 100}, + LSL: { code: "LSL", name: "Loti", minorUnits: 2, factor: 100, name: "Loti"}, // LYD currency object - LYD: { code: "LYD", name: "Libyan Dinar", minorUnits: 3, factor: 1000}, + LYD: { code: "LYD", name: "Libyan Dinar", minorUnits: 3, factor: 1000, name: "Libyan Dinar"}, // MAD currency object - MAD: { code: "MAD", name: "Moroccan Dirham", minorUnits: 2, factor: 100}, + MAD: { code: "MAD", name: "Moroccan Dirham", minorUnits: 2, factor: 100, name: "Moroccan Dirham"}, // MDL currency object - MDL: { code: "MDL", name: "Moldovan Leu", minorUnits: 2, factor: 100}, + MDL: { code: "MDL", name: "Moldovan Leu", minorUnits: 2, factor: 100, name: "Moldovan Leu"}, // MGA currency object - MGA: { code: "MGA", name: "Malagasy Ariary", minorUnits: 2, factor: 100}, + MGA: { code: "MGA", name: "Malagasy Ariary", minorUnits: 2, factor: 100, name: "Malagasy Ariary"}, // MKD currency object - MKD: { code: "MKD", name: "Denar", minorUnits: 2, factor: 100}, + MKD: { code: "MKD", name: "Denar", minorUnits: 2, factor: 100, name: "Denar"}, // MMK currency object - MMK: { code: "MMK", name: "Kyat", minorUnits: 2, factor: 100}, + MMK: { code: "MMK", name: "Kyat", minorUnits: 2, factor: 100, name: "Kyat"}, // MNT currency object - MNT: { code: "MNT", name: "Tugrik", minorUnits: 2, factor: 100}, + MNT: { code: "MNT", name: "Tugrik", minorUnits: 2, factor: 100, name: "Tugrik"}, // MOP currency object - MOP: { code: "MOP", name: "Pataca", minorUnits: 2, factor: 100}, + MOP: { code: "MOP", name: "Pataca", minorUnits: 2, factor: 100, name: "Pataca"}, // MRU currency object - MRU: { code: "MRU", name: "Ouguiya", minorUnits: 2, factor: 100}, + MRU: { code: "MRU", name: "Ouguiya", minorUnits: 2, factor: 100, name: "Ouguiya"}, // MUR currency object - MUR: { code: "MUR", name: "Mauritius Rupee", minorUnits: 2, factor: 100}, + MUR: { code: "MUR", name: "Mauritius Rupee", minorUnits: 2, factor: 100, name: "Mauritius Rupee"}, // MVR currency object - MVR: { code: "MVR", name: "Rufiyaa", minorUnits: 2, factor: 100}, + MVR: { code: "MVR", name: "Rufiyaa", minorUnits: 2, factor: 100, name: "Rufiyaa"}, // MWK currency object - MWK: { code: "MWK", name: "Malawi Kwacha", minorUnits: 2, factor: 100}, + MWK: { code: "MWK", name: "Malawi Kwacha", minorUnits: 2, factor: 100, name: "Malawi Kwacha"}, // MXN currency object - MXN: { code: "MXN", name: "Mexican Peso", minorUnits: 2, factor: 100}, + MXN: { code: "MXN", name: "Mexican Peso", minorUnits: 2, factor: 100, name: "Mexican Peso"}, // MXV currency object - MXV: { code: "MXV", name: "Mexican Unidad de Inversion (UDI)", minorUnits: 2, factor: 100}, + MXV: { code: "MXV", name: "Mexican Unidad de Inversion (UDI)", minorUnits: 2, factor: 100, name: "Mexican Unidad de Inversion (UDI)"}, // MYR currency object - MYR: { code: "MYR", name: "Malaysian Ringgit", minorUnits: 2, factor: 100}, + MYR: { code: "MYR", name: "Malaysian Ringgit", minorUnits: 2, factor: 100, name: "Malaysian Ringgit"}, // MZN currency object - MZN: { code: "MZN", name: "Mozambique Metical", minorUnits: 2, factor: 100}, + MZN: { code: "MZN", name: "Mozambique Metical", minorUnits: 2, factor: 100, name: "Mozambique Metical"}, // NAD currency object - NAD: { code: "NAD", name: "Namibia Dollar", minorUnits: 2, factor: 100}, + NAD: { code: "NAD", name: "Namibia Dollar", minorUnits: 2, factor: 100, name: "Namibia Dollar"}, // NGN currency object - NGN: { code: "NGN", name: "Naira", minorUnits: 2, factor: 100}, + NGN: { code: "NGN", name: "Naira", minorUnits: 2, factor: 100, name: "Naira"}, // NIO currency object - NIO: { code: "NIO", name: "Cordoba Oro", minorUnits: 2, factor: 100}, + NIO: { code: "NIO", name: "Cordoba Oro", minorUnits: 2, factor: 100, name: "Cordoba Oro"}, // NOK currency object - NOK: { code: "NOK", name: "Norwegian Krone", minorUnits: 2, factor: 100}, + NOK: { code: "NOK", name: "Norwegian Krone", minorUnits: 2, factor: 100, name: "Norwegian Krone"}, // NPR currency object - NPR: { code: "NPR", name: "Nepalese Rupee", minorUnits: 2, factor: 100}, + NPR: { code: "NPR", name: "Nepalese Rupee", minorUnits: 2, factor: 100, name: "Nepalese Rupee"}, // NZD currency object - NZD: { code: "NZD", name: "New Zealand Dollar", minorUnits: 2, factor: 100}, + NZD: { code: "NZD", name: "New Zealand Dollar", minorUnits: 2, factor: 100, name: "New Zealand Dollar"}, // OMR currency object - OMR: { code: "OMR", name: "Rial Omani", minorUnits: 3, factor: 1000}, + OMR: { code: "OMR", name: "Rial Omani", minorUnits: 3, factor: 1000, name: "Rial Omani"}, // PAB currency object - PAB: { code: "PAB", name: "Balboa", minorUnits: 2, factor: 100}, + PAB: { code: "PAB", name: "Balboa", minorUnits: 2, factor: 100, name: "Balboa"}, // PEN currency object - PEN: { code: "PEN", name: "Sol", minorUnits: 2, factor: 100}, + PEN: { code: "PEN", name: "Sol", minorUnits: 2, factor: 100, name: "Sol"}, // PGK currency object - PGK: { code: "PGK", name: "Kina", minorUnits: 2, factor: 100}, + PGK: { code: "PGK", name: "Kina", minorUnits: 2, factor: 100, name: "Kina"}, // PHP currency object - PHP: { code: "PHP", name: "Philippine Peso", minorUnits: 2, factor: 100}, + PHP: { code: "PHP", name: "Philippine Peso", minorUnits: 2, factor: 100, name: "Philippine Peso"}, // PKR currency object - PKR: { code: "PKR", name: "Pakistan Rupee", minorUnits: 2, factor: 100}, + PKR: { code: "PKR", name: "Pakistan Rupee", minorUnits: 2, factor: 100, name: "Pakistan Rupee"}, // PLN currency object - PLN: { code: "PLN", name: "Zloty", minorUnits: 2, factor: 100}, + PLN: { code: "PLN", name: "Zloty", minorUnits: 2, factor: 100, name: "Zloty"}, // PYG currency object - PYG: { code: "PYG", name: "Guarani", minorUnits: 0, factor: 1}, + PYG: { code: "PYG", name: "Guarani", minorUnits: 0, factor: 1, name: "Guarani"}, // QAR currency object - QAR: { code: "QAR", name: "Qatari Rial", minorUnits: 2, factor: 100}, + QAR: { code: "QAR", name: "Qatari Rial", minorUnits: 2, factor: 100, name: "Qatari Rial"}, // RON currency object - RON: { code: "RON", name: "Romanian Leu", minorUnits: 2, factor: 100}, + RON: { code: "RON", name: "Romanian Leu", minorUnits: 2, factor: 100, name: "Romanian Leu"}, // RSD currency object - RSD: { code: "RSD", name: "Serbian Dinar", minorUnits: 2, factor: 100}, + RSD: { code: "RSD", name: "Serbian Dinar", minorUnits: 2, factor: 100, name: "Serbian Dinar"}, // RUB currency object - RUB: { code: "RUB", name: "Russian Ruble", minorUnits: 2, factor: 100}, + RUB: { code: "RUB", name: "Russian Ruble", minorUnits: 2, factor: 100, name: "Russian Ruble"}, // RWF currency object - RWF: { code: "RWF", name: "Rwanda Franc", minorUnits: 0, factor: 1}, + RWF: { code: "RWF", name: "Rwanda Franc", minorUnits: 0, factor: 1, name: "Rwanda Franc"}, // SAR currency object - SAR: { code: "SAR", name: "Saudi Riyal", minorUnits: 2, factor: 100}, + SAR: { code: "SAR", name: "Saudi Riyal", minorUnits: 2, factor: 100, name: "Saudi Riyal"}, // SBD currency object - SBD: { code: "SBD", name: "Solomon Islands Dollar", minorUnits: 2, factor: 100}, + SBD: { code: "SBD", name: "Solomon Islands Dollar", minorUnits: 2, factor: 100, name: "Solomon Islands Dollar"}, // SCR currency object - SCR: { code: "SCR", name: "Seychelles Rupee", minorUnits: 2, factor: 100}, + SCR: { code: "SCR", name: "Seychelles Rupee", minorUnits: 2, factor: 100, name: "Seychelles Rupee"}, // SDG currency object - SDG: { code: "SDG", name: "Sudanese Pound", minorUnits: 2, factor: 100}, + SDG: { code: "SDG", name: "Sudanese Pound", minorUnits: 2, factor: 100, name: "Sudanese Pound"}, // SEK currency object - SEK: { code: "SEK", name: "Swedish Krona", minorUnits: 2, factor: 100}, + SEK: { code: "SEK", name: "Swedish Krona", minorUnits: 2, factor: 100, name: "Swedish Krona"}, // SGD currency object - SGD: { code: "SGD", name: "Singapore Dollar", minorUnits: 2, factor: 100}, + SGD: { code: "SGD", name: "Singapore Dollar", minorUnits: 2, factor: 100, name: "Singapore Dollar"}, // SHP currency object - SHP: { code: "SHP", name: "Saint Helena Pound", minorUnits: 2, factor: 100}, + SHP: { code: "SHP", name: "Saint Helena Pound", minorUnits: 2, factor: 100, name: "Saint Helena Pound"}, // SLE currency object - SLE: { code: "SLE", name: "Leone", minorUnits: 2, factor: 100}, + SLE: { code: "SLE", name: "Leone", minorUnits: 2, factor: 100, name: "Leone"}, // SOS currency object - SOS: { code: "SOS", name: "Somali Shilling", minorUnits: 2, factor: 100}, + SOS: { code: "SOS", name: "Somali Shilling", minorUnits: 2, factor: 100, name: "Somali Shilling"}, // SRD currency object - SRD: { code: "SRD", name: "Surinam Dollar", minorUnits: 2, factor: 100}, + SRD: { code: "SRD", name: "Surinam Dollar", minorUnits: 2, factor: 100, name: "Surinam Dollar"}, // SSP currency object - SSP: { code: "SSP", name: "South Sudanese Pound", minorUnits: 2, factor: 100}, + SSP: { code: "SSP", name: "South Sudanese Pound", minorUnits: 2, factor: 100, name: "South Sudanese Pound"}, // STN currency object - STN: { code: "STN", name: "Dobra", minorUnits: 2, factor: 100}, + STN: { code: "STN", name: "Dobra", minorUnits: 2, factor: 100, name: "Dobra"}, // SVC currency object - SVC: { code: "SVC", name: "El Salvador Colon", minorUnits: 2, factor: 100}, + SVC: { code: "SVC", name: "El Salvador Colon", minorUnits: 2, factor: 100, name: "El Salvador Colon"}, // SYP currency object - SYP: { code: "SYP", name: "Syrian Pound", minorUnits: 2, factor: 100}, + SYP: { code: "SYP", name: "Syrian Pound", minorUnits: 2, factor: 100, name: "Syrian Pound"}, // SZL currency object - SZL: { code: "SZL", name: "Lilangeni", minorUnits: 2, factor: 100}, + SZL: { code: "SZL", name: "Lilangeni", minorUnits: 2, factor: 100, name: "Lilangeni"}, // THB currency object - THB: { code: "THB", name: "Baht", minorUnits: 2, factor: 100}, + THB: { code: "THB", name: "Baht", minorUnits: 2, factor: 100, name: "Baht"}, // TJS currency object - TJS: { code: "TJS", name: "Somoni", minorUnits: 2, factor: 100}, + TJS: { code: "TJS", name: "Somoni", minorUnits: 2, factor: 100, name: "Somoni"}, // TMT currency object - TMT: { code: "TMT", name: "Turkmenistan New Manat", minorUnits: 2, factor: 100}, + TMT: { code: "TMT", name: "Turkmenistan New Manat", minorUnits: 2, factor: 100, name: "Turkmenistan New Manat"}, // TND currency object - TND: { code: "TND", name: "Tunisian Dinar", minorUnits: 3, factor: 1000}, + TND: { code: "TND", name: "Tunisian Dinar", minorUnits: 3, factor: 1000, name: "Tunisian Dinar"}, // TOP currency object - TOP: { code: "TOP", name: "Pa’anga", minorUnits: 2, factor: 100}, + TOP: { code: "TOP", name: "Pa’anga", minorUnits: 2, factor: 100, name: "Pa’anga"}, // TRY currency object - TRY: { code: "TRY", name: "Turkish Lira", minorUnits: 2, factor: 100}, + TRY: { code: "TRY", name: "Turkish Lira", minorUnits: 2, factor: 100, name: "Turkish Lira"}, // TTD currency object - TTD: { code: "TTD", name: "Trinidad and Tobago Dollar", minorUnits: 2, factor: 100}, + TTD: { code: "TTD", name: "Trinidad and Tobago Dollar", minorUnits: 2, factor: 100, name: "Trinidad and Tobago Dollar"}, // TWD currency object - TWD: { code: "TWD", name: "New Taiwan Dollar", minorUnits: 2, factor: 100}, + TWD: { code: "TWD", name: "New Taiwan Dollar", minorUnits: 2, factor: 100, name: "New Taiwan Dollar"}, // TZS currency object - TZS: { code: "TZS", name: "Tanzanian Shilling", minorUnits: 2, factor: 100}, + TZS: { code: "TZS", name: "Tanzanian Shilling", minorUnits: 2, factor: 100, name: "Tanzanian Shilling"}, // UAH currency object - UAH: { code: "UAH", name: "Hryvnia", minorUnits: 2, factor: 100}, + UAH: { code: "UAH", name: "Hryvnia", minorUnits: 2, factor: 100, name: "Hryvnia"}, // UGX currency object - UGX: { code: "UGX", name: "Uganda Shilling", minorUnits: 0, factor: 1}, + UGX: { code: "UGX", name: "Uganda Shilling", minorUnits: 0, factor: 1, name: "Uganda Shilling"}, // USD currency object - USD: { code: "USD", name: "US Dollar", minorUnits: 2, factor: 100}, + USD: { code: "USD", name: "US Dollar", minorUnits: 2, factor: 100, name: "US Dollar"}, // USN currency object - USN: { code: "USN", name: "US Dollar (Next day)", minorUnits: 2, factor: 100}, + USN: { code: "USN", name: "US Dollar (Next day)", minorUnits: 2, factor: 100, name: "US Dollar (Next day)"}, // UYI currency object - UYI: { code: "UYI", name: "Uruguay Peso en Unidades Indexadas (UI)", minorUnits: 0, factor: 1}, + UYI: { code: "UYI", name: "Uruguay Peso en Unidades Indexadas (UI)", minorUnits: 0, factor: 1, name: "Uruguay Peso en Unidades Indexadas (UI)"}, // UYU currency object - UYU: { code: "UYU", name: "Peso Uruguayo", minorUnits: 2, factor: 100}, + UYU: { code: "UYU", name: "Peso Uruguayo", minorUnits: 2, factor: 100, name: "Peso Uruguayo"}, // UYW currency object - UYW: { code: "UYW", name: "Unidad Previsional", minorUnits: 4, factor: 10000}, + UYW: { code: "UYW", name: "Unidad Previsional", minorUnits: 4, factor: 10000, name: "Unidad Previsional"}, // UZS currency object - UZS: { code: "UZS", name: "Uzbekistan Sum", minorUnits: 2, factor: 100}, + UZS: { code: "UZS", name: "Uzbekistan Sum", minorUnits: 2, factor: 100, name: "Uzbekistan Sum"}, // VED currency object - VED: { code: "VED", name: "Bolívar Soberano", minorUnits: 2, factor: 100}, + VED: { code: "VED", name: "Bolívar Soberano", minorUnits: 2, factor: 100, name: "Bolívar Soberano"}, // VES currency object - VES: { code: "VES", name: "Bolívar Soberano", minorUnits: 2, factor: 100}, + VES: { code: "VES", name: "Bolívar Soberano", minorUnits: 2, factor: 100, name: "Bolívar Soberano"}, // VND currency object - VND: { code: "VND", name: "Dong", minorUnits: 0, factor: 1}, + VND: { code: "VND", name: "Dong", minorUnits: 0, factor: 1, name: "Dong"}, // VUV currency object - VUV: { code: "VUV", name: "Vatu", minorUnits: 0, factor: 1}, + VUV: { code: "VUV", name: "Vatu", minorUnits: 0, factor: 1, name: "Vatu"}, // WST currency object - WST: { code: "WST", name: "Tala", minorUnits: 2, factor: 100}, + WST: { code: "WST", name: "Tala", minorUnits: 2, factor: 100, name: "Tala"}, // XAF currency object - XAF: { code: "XAF", name: "CFA Franc BEAC", minorUnits: 0, factor: 1}, + XAF: { code: "XAF", name: "CFA Franc BEAC", minorUnits: 0, factor: 1, name: "CFA Franc BEAC"}, // XAG currency object - XAG: { code: "XAG", name: "Silver", minorUnits: 0, factor: 1}, + XAG: { code: "XAG", name: "Silver", minorUnits: 0, factor: 1, name: "Silver"}, // XAU currency object - XAU: { code: "XAU", name: "Gold", minorUnits: 0, factor: 1}, + XAU: { code: "XAU", name: "Gold", minorUnits: 0, factor: 1, name: "Gold"}, // XBA currency object - XBA: { code: "XBA", name: "Bond Markets Unit European Composite Unit (EURCO)", minorUnits: 0, factor: 1}, + XBA: { code: "XBA", name: "Bond Markets Unit European Composite Unit (EURCO)", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Composite Unit (EURCO)"}, // XBB currency object - XBB: { code: "XBB", name: "Bond Markets Unit European Monetary Unit (E.M.U.-6)", minorUnits: 0, factor: 1}, + XBB: { code: "XBB", name: "Bond Markets Unit European Monetary Unit (E.M.U.-6)", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Monetary Unit (E.M.U.-6)"}, // XBC currency object - XBC: { code: "XBC", name: "Bond Markets Unit European Unit of Account 9 (E.U.A.-9)", minorUnits: 0, factor: 1}, + XBC: { code: "XBC", name: "Bond Markets Unit European Unit of Account 9 (E.U.A.-9)", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Unit of Account 9 (E.U.A.-9)"}, // XBD currency object - XBD: { code: "XBD", name: "Bond Markets Unit European Unit of Account 17 (E.U.A.-17)", minorUnits: 0, factor: 1}, + XBD: { code: "XBD", name: "Bond Markets Unit European Unit of Account 17 (E.U.A.-17)", minorUnits: 0, factor: 1, name: "Bond Markets Unit European Unit of Account 17 (E.U.A.-17)"}, // XCD currency object - XCD: { code: "XCD", name: "East Caribbean Dollar", minorUnits: 2, factor: 100}, + XCD: { code: "XCD", name: "East Caribbean Dollar", minorUnits: 2, factor: 100, name: "East Caribbean Dollar"}, // XDR currency object - XDR: { code: "XDR", name: "SDR (Special Drawing Right)", minorUnits: 0, factor: 1}, + XDR: { code: "XDR", name: "SDR (Special Drawing Right)", minorUnits: 0, factor: 1, name: "SDR (Special Drawing Right)"}, // XOF currency object - XOF: { code: "XOF", name: "CFA Franc BCEAO", minorUnits: 0, factor: 1}, + XOF: { code: "XOF", name: "CFA Franc BCEAO", minorUnits: 0, factor: 1, name: "CFA Franc BCEAO"}, // XPD currency object - XPD: { code: "XPD", name: "Palladium", minorUnits: 0, factor: 1}, + XPD: { code: "XPD", name: "Palladium", minorUnits: 0, factor: 1, name: "Palladium"}, // XPF currency object - XPF: { code: "XPF", name: "CFP Franc", minorUnits: 0, factor: 1}, + XPF: { code: "XPF", name: "CFP Franc", minorUnits: 0, factor: 1, name: "CFP Franc"}, // XPT currency object - XPT: { code: "XPT", name: "Platinum", minorUnits: 0, factor: 1}, + XPT: { code: "XPT", name: "Platinum", minorUnits: 0, factor: 1, name: "Platinum"}, // XSU currency object - XSU: { code: "XSU", name: "Sucre", minorUnits: 0, factor: 1}, + XSU: { code: "XSU", name: "Sucre", minorUnits: 0, factor: 1, name: "Sucre"}, // XTS currency object - XTS: { code: "XTS", name: "Codes specifically reserved for testing purposes", minorUnits: 0, factor: 1}, + XTS: { code: "XTS", name: "Codes specifically reserved for testing purposes", minorUnits: 0, factor: 1, name: "Codes specifically reserved for testing purposes"}, // XUA currency object - XUA: { code: "XUA", name: "ADB Unit of Account", minorUnits: 0, factor: 1}, + XUA: { code: "XUA", name: "ADB Unit of Account", minorUnits: 0, factor: 1, name: "ADB Unit of Account"}, // XXX currency object - XXX: { code: "XXX", name: "The codes assigned for transactions where no currency is involved", minorUnits: 0, factor: 1}, + XXX: { code: "XXX", name: "The codes assigned for transactions where no currency is involved", minorUnits: 0, factor: 1, name: "The codes assigned for transactions where no currency is involved"}, // YER currency object - YER: { code: "YER", name: "Yemeni Rial", minorUnits: 2, factor: 100}, + YER: { code: "YER", name: "Yemeni Rial", minorUnits: 2, factor: 100, name: "Yemeni Rial"}, // ZAR currency object - ZAR: { code: "ZAR", name: "Rand", minorUnits: 2, factor: 100}, + ZAR: { code: "ZAR", name: "Rand", minorUnits: 2, factor: 100, name: "Rand"}, // ZMW currency object - ZMW: { code: "ZMW", name: "Zambian Kwacha", minorUnits: 2, factor: 100}, + ZMW: { code: "ZMW", name: "Zambian Kwacha", minorUnits: 2, factor: 100, name: "Zambian Kwacha"}, // ZWG currency object - ZWG: { code: "ZWG", name: "Zimbabwe Gold", minorUnits: 2, factor: 100}, + ZWG: { code: "ZWG", name: "Zimbabwe Gold", minorUnits: 2, factor: 100, name: "Zimbabwe Gold"}, // ZWL currency object - ZWL: { code: "ZWL", name: "Zimbabwe Dollar", minorUnits: 2, factor: 100} + ZWL: { code: "ZWL", name: "Zimbabwe Dollar", minorUnits: 2, factor: 100, name: "Zimbabwe Dollar"} };