Class: Bedi::Cielo

Inherits:
Object
  • Object
show all
Includes:
ParsingHelpers
Defined in:
lib/bedi/cielo.rb

Instance Method Summary collapse

Methods included from ParsingHelpers

#parse_file

Instance Method Details

#parse(source) ⇒ Object



7
8
9
10
11
12
13
14
# File 'lib/bedi/cielo.rb', line 7

def parse(source)
  result = Parser.parse(source)

  formatted_batches = result[:Batch].map { |b| format_batch(b) }
  {
    batches: formatted_batches
  }
end