Module: ObjectTable::ViewMethods
- Extended by:
- Forwardable
- Includes:
- TableChild, TableMethods
- Included in:
- StaticView, View
- Defined in:
- lib/object_table/view_methods.rb
Instance Attribute Summary
Attributes included from TableMethods
Instance Method Summary collapse
Methods included from TableChild
#__group_cls__, #__static_view_cls__, #__table_cls__, #__view_cls__
Methods included from TableMethods
#==, #_get_sort_index, #apply, #clone, #colnames, #group_by, #initialize, #method_missing, #ncols, #nrows, #respond_to?, #set_column, #sort_by, #where
Methods included from Printable
get_printable_column, get_printable_line_numbers, #inspect
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class ObjectTable::TableMethods
Instance Method Details
#add_column(name, *args) ⇒ Object
14 15 16 17 |
# File 'lib/object_table/view_methods.rb', line 14 def add_column(name, *args) col = @parent.add_column(name, *args) ObjectTable::MaskedColumn.mask(col, indices) end |
#columns ⇒ Object
10 11 12 |
# File 'lib/object_table/view_methods.rb', line 10 def columns ObjectTable::BasicGrid[@parent.columns.map{|k, v| [k, ObjectTable::MaskedColumn.mask(v, indices)]}] end |
#pop_column(name) ⇒ Object
19 20 21 22 |
# File 'lib/object_table/view_methods.rb', line 19 def pop_column(name) @parent.pop_column(name) super if @columns end |