Sha256: 6bfd8dfef79f1f9180abbb92fc5ba4a210763b5c601c21fdf74b94702056692f

Contents?: true

Size: 265 Bytes

Versions: 4

Compression:

Stored size: 265 Bytes

Contents

class CsvtExtended < Roo::CSV
  def initialize(path)
    super(path, csv_options: { col_sep: "\t" })
  end

  def foreach(sheet = nil, &block)
    index = 1
    CSV.foreach(@filename, csv_options) do |row|
      yield(row, index)
      index += 1
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
simple-spreadsheet-0.5.0 lib/simple-spreadsheet/classes/csvt_extended.rb
simple-spreadsheet-0.4.3 lib/simple-spreadsheet/classes/csvt_extended.rb
simple-spreadsheet-0.4.2 lib/simple-spreadsheet/classes/csvt_extended.rb
simple-spreadsheet-0.4.1 lib/simple-spreadsheet/classes/csvt_extended.rb