Class: SeatGeek::Taxonomies::Theater
- Defined in:
- lib/seat_geek/taxonomies/theater.rb
Instance Attribute Summary collapse
-
#parent_id ⇒ Object
Returns the value of attribute parent_id.
-
#taxonomies ⇒ Object
Returns the value of attribute taxonomies.
Instance Method Summary collapse
- #all ⇒ Object
- #classical ⇒ Object
-
#initialize(child_taxonomies:, file_path:, type:) ⇒ Theater
constructor
A new instance of Theater.
Methods inherited from ChildTree
Constructor Details
#initialize(child_taxonomies:, file_path:, type:) ⇒ Theater
Returns a new instance of Theater.
4 5 6 7 |
# File 'lib/seat_geek/taxonomies/theater.rb', line 4 def initialize(child_taxonomies:, file_path:, type:) @taxonomies = child_taxonomies @yaml_hash = YAML.load_file(file_path).fetch('event_parent_id').fetch(type) end |
Instance Attribute Details
#parent_id ⇒ Object
Returns the value of attribute parent_id.
18 19 20 |
# File 'lib/seat_geek/taxonomies/theater.rb', line 18 def parent_id @parent_id end |
#taxonomies ⇒ Object
Returns the value of attribute taxonomies.
18 19 20 |
# File 'lib/seat_geek/taxonomies/theater.rb', line 18 def taxonomies @taxonomies end |
Instance Method Details
#all ⇒ Object
9 10 11 |
# File 'lib/seat_geek/taxonomies/theater.rb', line 9 def all taxonomies end |
#classical ⇒ Object
13 14 15 16 |
# File 'lib/seat_geek/taxonomies/theater.rb', line 13 def classical @parent_id = @yaml_hash.fetch('classical') build_child_tree end |