Class: StoreAsInt::ExchangeRate
- Defined in:
- lib/store_as_int/exchange_rate.rb
Constant Summary collapse
- ACCURACY =
Constants ============================================================
10- DECIMALS =
4- SYM =
'%'
Instance Attribute Summary
Attributes inherited from Base
Class Method Summary collapse
-
.extend_numerics ⇒ Object
Class Methods ========================================================.
Instance Method Summary collapse
-
#exchange_rate_str ⇒ Object
Instance Methods =====================================================.
- #to_exchange_rate ⇒ Object
Methods inherited from Base
#<=>, #==, #===, ===, accuracy, #accuracy, #as_json, #base, base, #base_float, #coerce, #convert, #decimals, decimals, #dup, #duplicable?, #initialize, #inspect, #instance_of?, #is_a?, #is_an?, #kind_of?, matcher, #matcher, #method_missing, #negative_sign, operators, #operators, #present?, str_format, sym, #sym, #sym=, #to_d, #to_f, #to_h, #to_i, #to_json, #to_s, #value
Constructor Details
This class inherits a constructor from StoreAsInt::Base
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class StoreAsInt::Base
Class Method Details
.extend_numerics ⇒ Object
Class Methods ========================================================
20 21 22 |
# File 'lib/store_as_int/exchange_rate.rb', line 20 def self.extend_numerics Numeric.include StoreAsInt::ActsAsExchangeRateInt end |
Instance Method Details
#exchange_rate_str ⇒ Object
Instance Methods =====================================================
29 30 31 |
# File 'lib/store_as_int/exchange_rate.rb', line 29 def exchange_rate_str to_s(true) end |
#to_exchange_rate ⇒ Object
33 34 35 |
# File 'lib/store_as_int/exchange_rate.rb', line 33 def to_exchange_rate self end |