Class: Seatsio::UsageByChart
- Inherits:
-
Object
- Object
- Seatsio::UsageByChart
- Defined in:
- lib/seatsio/domain.rb
Instance Attribute Summary collapse
-
#chart ⇒ Object
readonly
Returns the value of attribute chart.
-
#usage_by_event ⇒ Object
readonly
Returns the value of attribute usage_by_event.
Instance Method Summary collapse
-
#initialize(data) ⇒ UsageByChart
constructor
A new instance of UsageByChart.
Constructor Details
#initialize(data) ⇒ UsageByChart
Returns a new instance of UsageByChart.
518 519 520 521 |
# File 'lib/seatsio/domain.rb', line 518 def initialize(data) @chart = data['chart'] ? UsageChart.new(data['chart']) : nil @usage_by_event = data['usageByEvent'].map { |usage| UsageByEvent.new(usage) } end |
Instance Attribute Details
#chart ⇒ Object (readonly)
Returns the value of attribute chart.
516 517 518 |
# File 'lib/seatsio/domain.rb', line 516 def chart @chart end |
#usage_by_event ⇒ Object (readonly)
Returns the value of attribute usage_by_event.
516 517 518 |
# File 'lib/seatsio/domain.rb', line 516 def usage_by_event @usage_by_event end |