Class: Bismas::Parser::Legacy
- Inherits:
-
Bismas::Parser
- Object
- Bismas::Parser
- Bismas::Parser::Legacy
- Defined in:
- lib/bismas/parser.rb
Overview
Legacy version of Parser that more closely mimics the behaviour of the original BISMAS software. Deviations from Parser:
-
Records are not required to start with
0x01
, any character will do. -
Category numbers are extended to any character except
0x0D
0x0A
.
- NOT IMPLEMENTED YET
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Legacy
constructor
A new instance of Legacy.
Methods inherited from Bismas::Parser
parse, #parse, #parse_field, #parse_record
Constructor Details
#initialize(options = {}) ⇒ Legacy
Returns a new instance of Legacy.
58 59 60 61 62 63 64 |
# File 'lib/bismas/parser.rb', line 58 def initialize( = {}) raise NotImplementedError, 'not implemented yet' @category_char = '.' super @regex[:category] = /#{@regex[:category]}(?<!#{@chars[:newline]})/ end |