Module: OutputTypeable
- Included in:
- Nagira, Nagira::HostStatusController, Nagira::ResourceStatusController, Nagira::ServiceStatusController
- Defined in:
- app/concerns/output_typeable.rb
Instance Method Summary collapse
Instance Method Details
#body_with_list(body) ⇒ Object
14 15 16 17 18 19 20 |
# File 'app/concerns/output_typeable.rb', line 14 def body_with_list(body) if list? body.keys else body end end |
#full? ⇒ Boolean
10 11 12 |
# File 'app/concerns/output_typeable.rb', line 10 def full? @output == :full end |
#list? ⇒ Boolean
2 3 4 |
# File 'app/concerns/output_typeable.rb', line 2 def list? @output == :list end |
#state? ⇒ Boolean
6 7 8 |
# File 'app/concerns/output_typeable.rb', line 6 def state? @output == :state end |