Class: Aptible::CLI::Formatter::GroupedKeyedList
- Defined in:
- lib/aptible/cli/formatter/grouped_keyed_list.rb
Defined Under Namespace
Classes: InvalidGroup
Instance Attribute Summary collapse
-
#group ⇒ Object
readonly
Returns the value of attribute group.
Attributes inherited from KeyedList
Attributes inherited from List
Instance Method Summary collapse
- #groups ⇒ Object
-
#initialize(group, y) ⇒ GroupedKeyedList
constructor
A new instance of GroupedKeyedList.
Methods inherited from KeyedList
Methods inherited from List
Constructor Details
#initialize(group, y) ⇒ GroupedKeyedList
Returns a new instance of GroupedKeyedList.
15 16 17 18 19 |
# File 'lib/aptible/cli/formatter/grouped_keyed_list.rb', line 15 def initialize(group, y) @group = group validate_group! super(y) end |
Instance Attribute Details
#group ⇒ Object (readonly)
Returns the value of attribute group.
5 6 7 |
# File 'lib/aptible/cli/formatter/grouped_keyed_list.rb', line 5 def group @group end |
Instance Method Details
#groups ⇒ Object
21 22 23 |
# File 'lib/aptible/cli/formatter/grouped_keyed_list.rb', line 21 def groups children.group_by(&grouper) end |