public TMoney() { Amount = 0m; Currency = new TCurrency { CurrencyId = 0, CurrencyCode = "NA", Symbol = "" }; }
/// <summary> /// Represents an amount of TMoney in a specific currency. /// </summary> public TMoney(decimal amount, CurrencyTypes currencyType) : this(amount, TCurrency.Get(currencyType)) { }
/// <summary> /// Represents an amount of TMoney in a specific currency. /// </summary> public TMoney(decimal amount, String isoCurrencyCode) : this(amount, TCurrency.Get(isoCurrencyCode)) { }
/// <summary> /// Represents an amount of TMoney in a specific currency. /// </summary> public TMoney(decimal amount, int currencyId) : this(amount, TCurrency.Get(currencyId)) { }
/// <summary> /// Represents an amount of TMoney in a specific currency. /// </summary> public TMoney(decimal amount, TCurrency currency) : this() { Currency = currency; Amount = amount; }
/// <summary> /// Represents TMoney with the given currency and amount of 0 /// </summary> /// <param name="currency"></param> public TMoney(TCurrency currency) : this(0m, currency) { }
/// <summary> /// Represents an amount of TMoney in a specific currency. /// </summary> public TMoney(CurrencyTypes currencyType) : this(0m, TCurrency.Get(currencyType)) { }
/// <summary> /// Represents an amount of TMoney in a specific currency. /// </summary> public TMoney(string amount, String isoCurrencyCode) : this(decimal.Parse(amount), TCurrency.Get(isoCurrencyCode)) { }