Module: Extract

Defined in:
lib/extract.rb,
lib/extract.rb,
lib/extract.rb,
lib/extract/cell.rb,
lib/extract/sheet.rb,
lib/extract/table.rb,
lib/extract/parser.rb,
lib/extract/tables.rb,
lib/extract/tree/num.rb,
lib/extract/math_calc.rb,
lib/extract/tree/base.rb,
lib/extract/tree/cell.rb,
lib/extract/tree/math.rb,
lib/extract/export/ddl.rb,
lib/extract/inline_def.rb,
lib/extract/sheet_comp.rb,
lib/extract/tree/range.rb,
lib/extract/tree/string.rb,
lib/extract/export/table.rb,
lib/extract/tree/formula.rb,
lib/extract/persist/sheet.rb,
lib/extract/tree/cond_exp.rb,
lib/extract/tree/operator.rb,
lib/extract/excel_formulas.rb,
lib/extract/sheet_definition.rb,
lib/extract/tree/formula_args.rb

Defined Under Namespace

Modules: Export, Persist, Tree Classes: Cell, ExcelFormulas, InlineDef, MathCalc, MathWrapper, Parser, Row, Sheet, SheetComp, SheetDefinition, Table, Tables

Class Method Summary collapse

Class Method Details

.expand_cells(*arr) ⇒ Object



53
54
55
56
57
58
59
60
61
# File 'lib/extract.rb', line 53

def expand_cells(*arr)
  arr.flatten.map do |c|
    if c =~ /:/
      Extract::Tree::Range.cells_in_range(c)
    else
      c
    end
  end.flatten
end

.load!Object



29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# File 'lib/extract.rb', line 29

def load!
  %w(parser sheet excel_formulas math_calc sheet_definition cell inline_def table tables).each do |f|
    load File.expand_path(File.dirname(__FILE__)) + "/extract/#{f}.rb"
  end

  %w(base range cond_exp formula formula_args math num cell operator string).each do |f|
    load File.expand_path(File.dirname(__FILE__)) + "/extract/tree/#{f}.rb"
  end

  %w(sheet).each do |f|
    # load File.expand_path(File.dirname(__FILE__)) + "/extract/persist/#{f}.rb"
  end

  %w(ddl table).each do |f|
    load File.expand_path(File.dirname(__FILE__)) + "/extract/export/#{f}.rb"
  end
end