Class: HTMLNotes::Parser
- Inherits:
-
Object
- Object
- HTMLNotes::Parser
- Defined in:
- lib/html_notes/parser.rb
Instance Attribute Summary collapse
-
#file ⇒ Object
readonly
Returns the value of attribute file.
-
#line ⇒ Object
readonly
Returns the value of attribute line.
-
#notation ⇒ Object
readonly
Returns the value of attribute notation.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Instance Method Summary collapse
-
#initialize(line) ⇒ Parser
constructor
A new instance of Parser.
Constructor Details
#initialize(line) ⇒ Parser
Returns a new instance of Parser.
6 7 8 |
# File 'lib/html_notes/parser.rb', line 6 def initialize(line) @file, @line, @notation, @text = line.split(':') end |
Instance Attribute Details
#file ⇒ Object (readonly)
Returns the value of attribute file.
4 5 6 |
# File 'lib/html_notes/parser.rb', line 4 def file @file end |
#line ⇒ Object (readonly)
Returns the value of attribute line.
4 5 6 |
# File 'lib/html_notes/parser.rb', line 4 def line @line end |
#notation ⇒ Object (readonly)
Returns the value of attribute notation.
4 5 6 |
# File 'lib/html_notes/parser.rb', line 4 def notation @notation end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
4 5 6 |
# File 'lib/html_notes/parser.rb', line 4 def text @text end |