Class: Nineflats::Season
- Inherits:
-
Object
- Object
- Nineflats::Season
- Defined in:
- lib/nineflats-api/season.rb
Instance Attribute Summary collapse
-
#from ⇒ Object
Returns the value of attribute from.
-
#price ⇒ Object
Returns the value of attribute price.
-
#to ⇒ Object
Returns the value of attribute to.
-
#weekend_night_price ⇒ Object
Returns the value of attribute weekend_night_price.
Instance Method Summary collapse
-
#initialize(json) ⇒ Season
constructor
A new instance of Season.
Constructor Details
#initialize(json) ⇒ Season
Returns a new instance of Season.
5 6 7 8 9 10 11 12 |
# File 'lib/nineflats-api/season.rb', line 5 def initialize(json) season = json.first[1] @from = season["from"] @to = season["to"] @price = season["price"] @weekend_night_price = season["weekend_night_price"] end |
Instance Attribute Details
#from ⇒ Object
Returns the value of attribute from.
3 4 5 |
# File 'lib/nineflats-api/season.rb', line 3 def from @from end |
#price ⇒ Object
Returns the value of attribute price.
3 4 5 |
# File 'lib/nineflats-api/season.rb', line 3 def price @price end |
#to ⇒ Object
Returns the value of attribute to.
3 4 5 |
# File 'lib/nineflats-api/season.rb', line 3 def to @to end |
#weekend_night_price ⇒ Object
Returns the value of attribute weekend_night_price.
3 4 5 |
# File 'lib/nineflats-api/season.rb', line 3 def weekend_night_price @weekend_night_price end |