Class: TotalIn::Parser
- Inherits:
-
Object
- Object
- TotalIn::Parser
- Defined in:
- lib/total_in/parser.rb
Instance Attribute Summary collapse
-
#file ⇒ Object
readonly
Returns the value of attribute file.
Instance Method Summary collapse
-
#initialize(file) ⇒ Parser
constructor
Parser.new accepts a File instance or a String A InvalidFileFormatError will be raised if file isn’t in the TotalIn format.
- #result ⇒ Object
Constructor Details
#initialize(file) ⇒ Parser
Parser.new accepts a File instance or a String A InvalidFileFormatError will be raised if file isn’t in the TotalIn format
13 14 15 16 |
# File 'lib/total_in/parser.rb', line 13 def initialize file @file = file validate_file_format end |
Instance Attribute Details
#file ⇒ Object (readonly)
Returns the value of attribute file.
9 10 11 |
# File 'lib/total_in/parser.rb', line 9 def file @file end |