Class: TreasureData::FileReader::HashBuilder

Inherits:
Object
  • Object
show all
Defined in:
lib/td/file_reader.rb

Instance Method Summary collapse

Constructor Details

#initialize(parser, error, columns) ⇒ HashBuilder

Returns a new instance of HashBuilder.



225
226
227
228
# File 'lib/td/file_reader.rb', line 225

def initialize(parser, error, columns)
  @parser = parser
  @columns = columns
end

Instance Method Details

#forwardObject



230
231
232
233
# File 'lib/td/file_reader.rb', line 230

def forward
  array = @parser.forward
  Hash[@columns.zip(array)]
end