Module: Aptible::CLI::Formatter

Defined in:
lib/aptible/cli/formatter.rb,
lib/aptible/cli/formatter/list.rb,
lib/aptible/cli/formatter/node.rb,
lib/aptible/cli/formatter/root.rb,
lib/aptible/cli/formatter/value.rb,
lib/aptible/cli/formatter/object.rb,
lib/aptible/cli/formatter/keyed_list.rb,
lib/aptible/cli/formatter/keyed_object.rb,
lib/aptible/cli/formatter/grouped_keyed_list.rb

Defined Under Namespace

Classes: GroupedKeyedList, KeyedList, KeyedObject, List, Node, Object, Root, Value

Class Method Summary collapse

Class Method Details

.render(renderer) {|root| ... } ⇒ Object

Yields:



13
14
15
16
17
18
# File 'lib/aptible/cli/formatter.rb', line 13

def self.render(renderer)
  root = Root.new
  yield root
  out = renderer.render(root)
  puts out if out
end