Struct Currency
- Namespace
- DatabentoDotNet.Reference
- Assembly
- DatabentoDotNet.Reference.dll
A currency code — ISO 4217 alpha-3.
[JsonConverter(typeof(ReferenceCodeJsonConverter<Currency>))]
public readonly record struct Currency : IReferenceCode<Currency>, IEquatable<Currency>
- Implements
- Inherited Members
Remarks
An open set: a code this library does not know is carried, not lost. Upstream ends
this enum in an Unknown(String) variant (enums.rs:1169) so a code Databento adds
next month round-trips untouched, and a C# enum cannot hold a payload. See
IReferenceCode<TSelf> for the shape this takes instead and why.
The members come from the CUREN group of the vendored corporate_actions.list_enums response, which is the oracle rather than a count typed into an issue.
Constructors
Currency(string)
Wraps a wire code, known or not. Prefer a named member such as Aed where one exists, and From(string?) where the value came from the server.
public Currency(string code)
Parameters
codestringThe wire code.
Exceptions
- ArgumentException
codeis null or empty. A blank code is the absence of a value, which is default.
Properties
Aed
UAE Dirham (AED).
public static Currency Aed { get; }
Property Value
Afn
Afghanis (AFN).
public static Currency Afn { get; }
Property Value
All
Albanian Lek (ALL).
public static Currency All { get; }
Property Value
Amd
Armenian Dram (AMD).
public static Currency Amd { get; }
Property Value
Ang
Netherlands Antilles Guilders (ANG).
public static Currency Ang { get; }
Property Value
Aoa
Angola Kwanza (AOA).
public static Currency Aoa { get; }
Property Value
Ars
Argentine Peso (ARS).
public static Currency Ars { get; }
Property Value
Aud
Australian Dollar (AUD).
public static Currency Aud { get; }
Property Value
Awg
Aruban Guilder (AWG).
public static Currency Awg { get; }
Property Value
Azn
Azerbaijani Manat (AZN).
public static Currency Azn { get; }
Property Value
Bam
Convertible Marks (BAM).
public static Currency Bam { get; }
Property Value
Bbd
Barbados Dollar (BBD).
public static Currency Bbd { get; }
Property Value
Bdt
Bangladesh Taka (BDT).
public static Currency Bdt { get; }
Property Value
Bgn
Bulgarian Lev (BGN).
public static Currency Bgn { get; }
Property Value
Bhd
Bahraini Dinar (BHD).
public static Currency Bhd { get; }
Property Value
Bif
Burundi Franc (BIF).
public static Currency Bif { get; }
Property Value
Bmd
Bermuda Dollar (BMD).
public static Currency Bmd { get; }
Property Value
Bnd
Brunei Dollar (BND).
public static Currency Bnd { get; }
Property Value
Bob
Boliviano (BOB).
public static Currency Bob { get; }
Property Value
Bov
Mvdol (BOV).
public static Currency Bov { get; }
Property Value
Brl
Brazilian Real (BRL).
public static Currency Brl { get; }
Property Value
Bsd
Bahamas Dollar (BSD).
public static Currency Bsd { get; }
Property Value
Btn
Bhutanese Ngultrum (BTN).
public static Currency Btn { get; }
Property Value
Bwp
Botswana Pula (BWP).
public static Currency Bwp { get; }
Property Value
Byn
Belarusian Ruble (New) (BYN).
public static Currency Byn { get; }
Property Value
Bzd
Belize Dollar (BZD).
public static Currency Bzd { get; }
Property Value
Cad
Canadian Dollar (CAD).
public static Currency Cad { get; }
Property Value
Cdf
Congolese Franc (CDF).
public static Currency Cdf { get; }
Property Value
Chf
Swiss Francs (CHF).
public static Currency Chf { get; }
Property Value
Clf
Chilean Unidad de Fomento (CLF).
public static Currency Clf { get; }
Property Value
Clp
Chilean Peso (CLP).
public static Currency Clp { get; }
Property Value
Cny
Chinese Yuan Renminbi (CNY).
public static Currency Cny { get; }
Property Value
Code
The wire code, or null when this names no value.
public string? Code { get; }
Property Value
Cop
Colombian Peso (COP).
public static Currency Cop { get; }
Property Value
Cou
Colombian (Unidad de Valor Real) (COU).
public static Currency Cou { get; }
Property Value
Crc
Costa Rican Colon (CRC).
public static Currency Crc { get; }
Property Value
Cup
Cuban Peso (CUP).
public static Currency Cup { get; }
Property Value
Cve
Cape Verde Escudo (CVE).
public static Currency Cve { get; }
Property Value
Cyp
Cypriot Pound (CYP).
public static Currency Cyp { get; }
Property Value
Czk
Czech Koruna (CZK).
public static Currency Czk { get; }
Property Value
Djf
Djibouti Franc (DJF).
public static Currency Djf { get; }
Property Value
Dkk
Danish Kroner (DKK).
public static Currency Dkk { get; }
Property Value
Dop
Dominican Peso (DOP).
public static Currency Dop { get; }
Property Value
Dzd
Algerian Dinar (DZD).
public static Currency Dzd { get; }
Property Value
Ecs
Ecuador Sucre (ECS).
public static Currency Ecs { get; }
Property Value
Eek
Estonian Kroon (EEK).
public static Currency Eek { get; }
Property Value
Egp
Egyptian Pound (EGP).
public static Currency Egp { get; }
Property Value
Ern
Eritrean Nakfa (ERN).
public static Currency Ern { get; }
Property Value
Etb
Ethiopian Birr (ETB).
public static Currency Etb { get; }
Property Value
Eur
Euros (EUR).
public static Currency Eur { get; }
Property Value
Fjd
Fiji Dollar (FJD).
public static Currency Fjd { get; }
Property Value
Fkp
Falklands Pounds (FKP).
public static Currency Fkp { get; }
Property Value
Gbp
Pound Sterling (GBP).
public static Currency Gbp { get; }
Property Value
Gbx
GB Pence (GBX).
public static Currency Gbx { get; }
Property Value
Gel
Georgian Lari (GEL).
public static Currency Gel { get; }
Property Value
Ghs
Ghanaian Cedi (GHS).
public static Currency Ghs { get; }
Property Value
Gip
Gibraltar Pounds (GIP).
public static Currency Gip { get; }
Property Value
Gmd
Gambian Dalasi (GMD).
public static Currency Gmd { get; }
Property Value
Gnf
Guinean Franc (GNF).
public static Currency Gnf { get; }
Property Value
Grd
Greek Drachma (GRD).
public static Currency Grd { get; }
Property Value
Gtq
Guatamala Quetzal (GTQ).
public static Currency Gtq { get; }
Property Value
Gyd
Guyana Dollar (GYD).
public static Currency Gyd { get; }
Property Value
HasValue
true when this names a code — known or not.
public bool HasValue { get; }
Property Value
Hkd
Hong Kong Dollar (HKD).
public static Currency Hkd { get; }
Property Value
Hnl
Honduras Lempira (HNL).
public static Currency Hnl { get; }
Property Value
Hrk
Croatian Kuna (HRK).
public static Currency Hrk { get; }
Property Value
Htg
Haiti Gourde (HTG).
public static Currency Htg { get; }
Property Value
Huf
Hungarian Forint (HUF).
public static Currency Huf { get; }
Property Value
Idr
Indonesian Rupiah (IDR).
public static Currency Idr { get; }
Property Value
Ils
Israeli New Shekel (ILS).
public static Currency Ils { get; }
Property Value
Inr
Indian Rupees (INR).
public static Currency Inr { get; }
Property Value
Iqd
Iraqi Dinar (IQD).
public static Currency Iqd { get; }
Property Value
Irr
Iranian Rial (IRR).
public static Currency Irr { get; }
Property Value
IsKnown
true when Code is one of KnownCodes.
public bool IsKnown { get; }
Property Value
Remarks
false is not an error. It means the server sent something newer than the table this library shipped with, and the code is still in Code to be read, logged, or sent back in a filter.
Isk
Icelandic Krona (ISK).
public static Currency Isk { get; }
Property Value
Jmd
Jamaican Dollar (JMD).
public static Currency Jmd { get; }
Property Value
Jod
Jordanian Dinar (JOD).
public static Currency Jod { get; }
Property Value
Jpy
Japanese Yen (JPY).
public static Currency Jpy { get; }
Property Value
Kes
Kenyan Shilling (KES).
public static Currency Kes { get; }
Property Value
Kgs
Kyrgyzstan Som (KGS).
public static Currency Kgs { get; }
Property Value
Khr
Cambodian Riel (KHR).
public static Currency Khr { get; }
Property Value
Kmf
Comoro Franc (KMF).
public static Currency Kmf { get; }
Property Value
KnownCodes
Every code the reference API reported for this type when the fixture was captured — 179 of them.
public static IReadOnlySet<string> KnownCodes { get; }
Property Value
Kpw
North Korean Won (KPW).
public static Currency Kpw { get; }
Property Value
Krw
Korean Won (KRW).
public static Currency Krw { get; }
Property Value
Kwd
Kuwaiti Dinar (KWD).
public static Currency Kwd { get; }
Property Value
Kyd
Cayman Islands Dollar (KYD).
public static Currency Kyd { get; }
Property Value
Kzt
Kazakhstan Tenge (KZT).
public static Currency Kzt { get; }
Property Value
Lak
Lao Liberation Kip (LAK).
public static Currency Lak { get; }
Property Value
Lbp
Lebanese Pound (LBP).
public static Currency Lbp { get; }
Property Value
Lkr
Sri Lankan Rupee (LKR).
public static Currency Lkr { get; }
Property Value
Lrd
Liberian Dollar (LRD).
public static Currency Lrd { get; }
Property Value
Lsl
Lesotho Loti (LSL).
public static Currency Lsl { get; }
Property Value
Ltl
Lithuanian Litas (LTL).
public static Currency Ltl { get; }
Property Value
Lyd
Libyan Dinar (LYD).
public static Currency Lyd { get; }
Property Value
Mad
Moroccan Dirham (MAD).
public static Currency Mad { get; }
Property Value
Mdl
Moldovan Leu (MDL).
public static Currency Mdl { get; }
Property Value
Mga
Malagasy Ariary (MGA).
public static Currency Mga { get; }
Property Value
Mkd
Macedonian Denar (MKD).
public static Currency Mkd { get; }
Property Value
Mmk
Myanmar Kyat (MMK).
public static Currency Mmk { get; }
Property Value
Mnt
Mongolian Tugrik (MNT).
public static Currency Mnt { get; }
Property Value
Mop
Macau Pataca (MOP).
public static Currency Mop { get; }
Property Value
Mro
Mauritanian Ouguiya (MRO).
public static Currency Mro { get; }
Property Value
Mur
Mauritius Rupee (MUR).
public static Currency Mur { get; }
Property Value
Mvr
Maldivian Rufiyaa (MVR).
public static Currency Mvr { get; }
Property Value
Mwk
Malawi Kwacha (MWK).
public static Currency Mwk { get; }
Property Value
Mxn
Mexican Nuevo Peso (MXN).
public static Currency Mxn { get; }
Property Value
Mxv
Mexican Unidad de Inversion (UDI) (MXV).
public static Currency Mxv { get; }
Property Value
Myr
Malaysian Ringgit (MYR).
public static Currency Myr { get; }
Property Value
Mzn
Mozambique Metical (MZN).
public static Currency Mzn { get; }
Property Value
Nad
Namibian Dollar (NAD).
public static Currency Nad { get; }
Property Value
Ngn
Nigerian Naira (NGN).
public static Currency Ngn { get; }
Property Value
Nio
Nicaraguan Cordoba Oro (NIO).
public static Currency Nio { get; }
Property Value
Nok
Norwegian Krone (NOK).
public static Currency Nok { get; }
Property Value
Npr
Nepalese Rupee (NPR).
public static Currency Npr { get; }
Property Value
Nzd
New Zealand Dollar (NZD).
public static Currency Nzd { get; }
Property Value
Omr
Omani Rial (OMR).
public static Currency Omr { get; }
Property Value
Pab
Panama Balboa (PAB).
public static Currency Pab { get; }
Property Value
Pen
Peruvian Nuevo Sol (PEN).
public static Currency Pen { get; }
Property Value
Pgk
Papua New Guinea Kina (PGK).
public static Currency Pgk { get; }
Property Value
Php
Philippines Peso (PHP).
public static Currency Php { get; }
Property Value
Pkr
Pakistan Rupee (PKR).
public static Currency Pkr { get; }
Property Value
Pln
Polish Złoty (New) (PLN).
public static Currency Pln { get; }
Property Value
Pyg
Paraguay Guarani (PYG).
public static Currency Pyg { get; }
Property Value
Qar
Qatar Rial (QAR).
public static Currency Qar { get; }
Property Value
Ron
Romanian Leu (New) (RON).
public static Currency Ron { get; }
Property Value
Rsd
Serbian Dinars (RSD).
public static Currency Rsd { get; }
Property Value
Rub
Russian Ruble (New) (RUB).
public static Currency Rub { get; }
Property Value
Rwf
Rwandan Franc (RWF).
public static Currency Rwf { get; }
Property Value
Sar
Saudi Arabian Riyal (SAR).
public static Currency Sar { get; }
Property Value
Sbd
Solomon Islands Dollar (SBD).
public static Currency Sbd { get; }
Property Value
Scr
Seychelles Rupee (SCR).
public static Currency Scr { get; }
Property Value
Sdd
Sudanese Dinar (SDD).
public static Currency Sdd { get; }
Property Value
Sdg
Sudanese Pound (SDG).
public static Currency Sdg { get; }
Property Value
Sek
Swedish Kroner (SEK).
public static Currency Sek { get; }
Property Value
Sgd
Singapore Dollar (SGD).
public static Currency Sgd { get; }
Property Value
Shp
St. Helena Pounds (SHP).
public static Currency Shp { get; }
Property Value
Sll
Sierra Leone (SLL).
public static Currency Sll { get; }
Property Value
Sos
Somalia Shilling (SOS).
public static Currency Sos { get; }
Property Value
Srd
Surinam Dollar (SRD).
public static Currency Srd { get; }
Property Value
Std
Sao Tome and Principe Dobra (STD).
public static Currency Std { get; }
Property Value
Svc
El Salvador Colon (SVC).
public static Currency Svc { get; }
Property Value
Syp
Syrian Pound (SYP).
public static Currency Syp { get; }
Property Value
Szl
Swaziland Lilangeni (SZL).
public static Currency Szl { get; }
Property Value
Thb
Thai Baht (THB).
public static Currency Thb { get; }
Property Value
Tjs
Tajikistani Somoni (TJS).
public static Currency Tjs { get; }
Property Value
Tmm
Turkmenistan Manat (TMM).
public static Currency Tmm { get; }
Property Value
Tnd
Tunisian Dinar (TND).
public static Currency Tnd { get; }
Property Value
Top
Tonga Pa`anga (TOP).
public static Currency Top { get; }
Property Value
Try
Turkish Lira (New) (TRY).
public static Currency Try { get; }
Property Value
Ttd
Trinidad and Tobago Dollar (TTD).
public static Currency Ttd { get; }
Property Value
Twd
Taiwan Dollar (TWD).
public static Currency Twd { get; }
Property Value
Tzs
Tanzanian Shilling (TZS).
public static Currency Tzs { get; }
Property Value
Uah
Ukrainian Hryvnia (UAH).
public static Currency Uah { get; }
Property Value
Ugx
Ugandan Shilling (UGX).
public static Currency Ugx { get; }
Property Value
Usd
US Dollar (USD).
public static Currency Usd { get; }
Property Value
Usx
US Cents (USX).
public static Currency Usx { get; }
Property Value
Uyi
Uruguay Peso (Index Linked) (UYI).
public static Currency Uyi { get; }
Property Value
Uyu
Uruguayan Peso (UYU).
public static Currency Uyu { get; }
Property Value
Uyw
Uruguayan Unidad Previsional (Pension Unit) (UYW).
public static Currency Uyw { get; }
Property Value
Uzs
Uzbekistan Sum (UZS).
public static Currency Uzs { get; }
Property Value
Vef
Venezuala Bolivares Fuertes (VEF).
public static Currency Vef { get; }
Property Value
Ves
Venezuela Sovereign Bolivar (VES).
public static Currency Ves { get; }
Property Value
Vnd
Vietnamese Dong (VND).
public static Currency Vnd { get; }
Property Value
Vuv
Vanuatu Vatu (VUV).
public static Currency Vuv { get; }
Property Value
Wst
Samoan Tala (WST).
public static Currency Wst { get; }
Property Value
Xaf
CFA Franc (BEAC) (XAF).
public static Currency Xaf { get; }
Property Value
Xcd
Caribbean Dollar (XCD).
public static Currency Xcd { get; }
Property Value
Xdr
International Monetary Fund (XDR).
public static Currency Xdr { get; }
Property Value
Xfu
UIC-Franc (XFU).
public static Currency Xfu { get; }
Property Value
Xof
CFA Franc (BCEAO) (XOF).
public static Currency Xof { get; }
Property Value
Xpf
CFP Franc (XPF).
public static Currency Xpf { get; }
Property Value
Xts
Codes for testing purposes (XTS).
public static Currency Xts { get; }
Property Value
Xxx
Codes for transactions/no currencies involved (XXX).
public static Currency Xxx { get; }
Property Value
Yer
North Yemen Rial (YER).
public static Currency Yer { get; }
Property Value
Zac
South African Cents (ZAC).
public static Currency Zac { get; }
Property Value
Zar
South African Rand (ZAR).
public static Currency Zar { get; }
Property Value
Zmk
Zambian Kwacha (ZMK).
public static Currency Zmk { get; }
Property Value
Zmw
Zambian New Kwacha (ZMW).
public static Currency Zmw { get; }
Property Value
Zrn
New Zaire (ZRN).
public static Currency Zrn { get; }
Property Value
Zwd
Zimbabwe Dollar (ZWD).
public static Currency Zwd { get; }
Property Value
Zwg
Zimbabwe Gold (ZWG).
public static Currency Zwg { get; }
Property Value
Zwl
Zimbabwean Dollar (ZWL).
public static Currency Zwl { get; }
Property Value
Methods
From(string?)
public static Currency From(string? code)
Parameters
Returns
- Currency
The value.
ToString()
The wire code, or the empty string when this names no value.
public override string ToString()
Returns
- string
The wire code.