Class: LockstepSdk::CurrencyRateModel
- Inherits:
-
Object
- Object
- LockstepSdk::CurrencyRateModel
- Defined in:
- lib/lockstep_sdk/models/currency_rate_model.rb
Overview
Represents a currency rate for specific currencies and date
Instance Attribute Summary collapse
-
#currency_rate ⇒ Double
The currency rate value.
-
#date ⇒ Date
The date for the currency rate.
-
#destination_currency ⇒ String
The destination currency.
-
#source_currency ⇒ String
The source currency.
Instance Method Summary collapse
-
#initialize(params = {}) ⇒ CurrencyRateModel
constructor
Initialize the CurrencyRateModel using the provided prototype.
Constructor Details
#initialize(params = {}) ⇒ CurrencyRateModel
Initialize the CurrencyRateModel using the provided prototype
24 25 26 27 28 29 |
# File 'lib/lockstep_sdk/models/currency_rate_model.rb', line 24 def initialize(params = {}) @source_currency = params.dig(:source_currency) @destination_currency = params.dig(:destination_currency) @date = params.dig(:date) @currency_rate = params.dig(:currency_rate) end |
Instance Attribute Details
#currency_rate ⇒ Double
Returns The currency rate value.
38 39 40 |
# File 'lib/lockstep_sdk/models/currency_rate_model.rb', line 38 def currency_rate @currency_rate end |
#date ⇒ Date
Returns The date for the currency rate.
36 37 38 |
# File 'lib/lockstep_sdk/models/currency_rate_model.rb', line 36 def date @date end |
#destination_currency ⇒ String
Returns The destination currency.
34 35 36 |
# File 'lib/lockstep_sdk/models/currency_rate_model.rb', line 34 def destination_currency @destination_currency end |
#source_currency ⇒ String
Returns The source currency.
32 33 34 |
# File 'lib/lockstep_sdk/models/currency_rate_model.rb', line 32 def source_currency @source_currency end |