Money::Currency::Enumeration
Inherits Enumerable
Instance methods
[](key : String | Symbol) : Currency
Lookup a currency with given key an returns a Currency instance on
success, raises UnknownCurrencyError otherwise.
Money::Currency.find("EUR") # => #<Money::Currency @id="eur">
Money::Currency.find("FOO") # => raises UnknownCurrencyError
[]?(key : String | Symbol) : Currency | Nil
Lookup a currency with given key an returns a Currency instance on
success, nil otherwise.
Money::Currency.find("EUR") # => #<Money::Currency @id="eur">
Money::Currency.find("FOO") # => nil
all
Sourcefind(key : String | Symbol) : Currency
Lookup a currency with given key an returns a Currency instance on
success, raises UnknownCurrencyError otherwise.
Money::Currency.find("EUR") # => #<Money::Currency @id="eur">
Money::Currency.find("FOO") # => raises UnknownCurrencyError
find?(key : String | Symbol) : Currency | Nil
Lookup a currency with given key an returns a Currency instance on
success, nil otherwise.
Money::Currency.find("EUR") # => #<Money::Currency @id="eur">
Money::Currency.find("FOO") # => nil