Class: BinderCore::TextParser

Inherits:
Parser
  • Object
show all
Defined in:
lib/binder_core/parsers/text_parser.rb

Instance Method Summary collapse

Methods inherited from Parser

#add, #console, #descend, #file, #initialize, #key, #key=, #new_asset, #params

Constructor Details

This class inherits a constructor from BinderCore::Parser

Instance Method Details

#parseObject



3
4
5
# File 'lib/binder_core/parsers/text_parser.rb', line 3

def parse
  add read_utf
end

#read_utfObject



7
8
9
# File 'lib/binder_core/parsers/text_parser.rb', line 7

def read_utf
  File.open( self.file.path, 'r:UTF-8') { |f| f.read } 
end