class Coopy::Tables
Attributes
alignment[RW]
table_order[RW]
tables[RW]
template[RW]
Public Class Methods
new(template)
click to toggle source
# File lib/lib/coopy/tables.rb, line 7 def initialize(template) @template = template @tables = {} @table_order = Array.new end
Public Instance Methods
add(name)
click to toggle source
# File lib/lib/coopy/tables.rb, line 23 def add(name) t = @template.clone @tables[name] = t @table_order.push(name) t end
get(name)
click to toggle source
# File lib/lib/coopy/tables.rb, line 34 def get(name) @tables[name] end
get_order()
click to toggle source
# File lib/lib/coopy/tables.rb, line 30 def get_order @table_order end
has_ins_del()
click to toggle source
# File lib/lib/coopy/tables.rb, line 42 def has_ins_del return false if @alignment == nil return true if @alignment.has_addition return true if @alignment.has_removal false end
one()
click to toggle source
# File lib/lib/coopy/tables.rb, line 38 def one @tables[@table_order[0]] end