Class: Parxer::XlsParser
Instance Attribute Summary
Attributes inherited from BaseParser
#attribute, #file, #prev_row, #row, #value
Instance Method Summary
collapse
Methods inherited from BaseParser
#file_extension, #header, #rows_count, #run
#for_each_ancestor_with_method, #inherited_collection, #inherited_hash, #object_ancestors
Instance Method Details
7
8
9
|
# File 'lib/parxer/parsers/xls_parser.rb', line 7
def (value)
value.is_a?(Spreadsheet::Formula) ? value.value : value
end
|
#raw_rows ⇒ Object
3
4
5
|
# File 'lib/parxer/parsers/xls_parser.rb', line 3
def raw_rows
worksheet
end
|
#workbook ⇒ Object
15
16
17
|
# File 'lib/parxer/parsers/xls_parser.rb', line 15
def workbook
@workbook ||= Roo::Spreadsheet.open(file, parser_config)
end
|
#worksheet ⇒ Object
11
12
13
|
# File 'lib/parxer/parsers/xls_parser.rb', line 11
def worksheet
@worksheet ||= workbook.sheet(0)
end
|