Module: Parliament::Grom::Decorator::HouseSeat
- Defined in:
- lib/parliament/grom/decorator/house_seat.rb
Overview
Decorator namespace for Grom::Node instances with type: id.parliament.uk/schema/HouseSeat
Instance Method Summary collapse
-
#constituency ⇒ Grom::Node?
Alias houseSeatHasConstituencyGroup with fallback.
-
#house ⇒ Grom::Node?
Alias houseSeatHasHouse with fallback.
-
#seat_incumbencies ⇒ Array
Alias houseSeatHasSeatIncumbency with fallback.
Instance Method Details
#constituency ⇒ Grom::Node?
Alias houseSeatHasConstituencyGroup with fallback.
16 17 18 |
# File 'lib/parliament/grom/decorator/house_seat.rb', line 16 def constituency respond_to?(:houseSeatHasConstituencyGroup) ? houseSeatHasConstituencyGroup.first : nil end |
#house ⇒ Grom::Node?
Alias houseSeatHasHouse with fallback.
9 10 11 |
# File 'lib/parliament/grom/decorator/house_seat.rb', line 9 def house respond_to?(:houseSeatHasHouse) ? houseSeatHasHouse.first : nil end |
#seat_incumbencies ⇒ Array
Alias houseSeatHasSeatIncumbency with fallback.
23 24 25 |
# File 'lib/parliament/grom/decorator/house_seat.rb', line 23 def seat_incumbencies respond_to?(:houseSeatHasSeatIncumbency) ? houseSeatHasSeatIncumbency : [] end |