Class: ExchangeRate
- Inherits:
-
Object
- Object
- ExchangeRate
- Defined in:
- lib/yahoo_currency/exchange_rate.rb
Instance Attribute Summary collapse
-
#from ⇒ Object
Returns the value of attribute from.
-
#rate ⇒ Object
Returns the value of attribute rate.
-
#timestamp ⇒ Object
Returns the value of attribute timestamp.
-
#to ⇒ Object
Returns the value of attribute to.
Instance Method Summary collapse
-
#initialize(from, to, rate, timestamp) ⇒ ExchangeRate
constructor
A new instance of ExchangeRate.
Constructor Details
#initialize(from, to, rate, timestamp) ⇒ ExchangeRate
Returns a new instance of ExchangeRate.
5 6 7 8 9 10 |
# File 'lib/yahoo_currency/exchange_rate.rb', line 5 def initialize(from, to, rate, ) @from = from @to = to @rate = rate @timestamp = end |
Instance Attribute Details
#from ⇒ Object
Returns the value of attribute from.
3 4 5 |
# File 'lib/yahoo_currency/exchange_rate.rb', line 3 def from @from end |
#rate ⇒ Object
Returns the value of attribute rate.
3 4 5 |
# File 'lib/yahoo_currency/exchange_rate.rb', line 3 def rate @rate end |
#timestamp ⇒ Object
Returns the value of attribute timestamp.
3 4 5 |
# File 'lib/yahoo_currency/exchange_rate.rb', line 3 def @timestamp end |
#to ⇒ Object
Returns the value of attribute to.
3 4 5 |
# File 'lib/yahoo_currency/exchange_rate.rb', line 3 def to @to end |