Class: Rgviz::TableBuilder
- Inherits:
-
Object
- Object
- Rgviz::TableBuilder
- Defined in:
- lib/rgviz/table_builder.rb
Instance Method Summary collapse
- #add_row(*values) ⇒ Object
-
#initialize(columns = []) ⇒ TableBuilder
constructor
A new instance of TableBuilder.
- #table ⇒ Object
Constructor Details
Instance Method Details
#add_row(*values) ⇒ Object
14 15 16 17 18 |
# File 'lib/rgviz/table_builder.rb', line 14 def add_row(*values) @table.rows << Rgviz::Row.new( :c => values.map { |value| Rgviz::Cell.new(:v => value) } ) end |
#table ⇒ Object
10 11 12 |
# File 'lib/rgviz/table_builder.rb', line 10 def table @table end |