class Moonshot::StackListPrinter
Attributes
stacks[RW]
Public Class Methods
new(stacks)
click to toggle source
# File lib/moonshot/stack_list_printer.rb, line 5 def initialize(stacks) @stacks = stacks @table = UnicodeTable.new('Environment List') end
Public Instance Methods
print()
click to toggle source
# File lib/moonshot/stack_list_printer.rb, line 10 def print rows = @stacks.map do |stack| [stack.name, stack.creation_time, stack.status] end @table.add_table(rows) @table.draw @table.draw_children end