Class: TreasureData::FileReader::DelimiterParser
- Inherits:
-
Object
- Object
- TreasureData::FileReader::DelimiterParser
- Defined in:
- lib/td/file_reader.rb
Instance Method Summary collapse
- #forward ⇒ Object
-
#initialize(reader, error, opts) ⇒ DelimiterParser
constructor
A new instance of DelimiterParser.
Constructor Details
#initialize(reader, error, opts) ⇒ DelimiterParser
Returns a new instance of DelimiterParser.
71 72 73 74 |
# File 'lib/td/file_reader.rb', line 71 def initialize(reader, error, opts) @reader = reader @delimiter_expr = opts[:delimiter_expr] end |
Instance Method Details
#forward ⇒ Object
76 77 78 79 |
# File 'lib/td/file_reader.rb', line 76 def forward row = @reader.forward_row array = row.split(@delimiter_expr) end |