Class: RDF::Turtle::Reader::SyntaxError
- Inherits:
-
ReaderError
- Object
- ReaderError
- RDF::Turtle::Reader::SyntaxError
- Defined in:
- lib/rdf/turtle/reader.rb
Instance Attribute Summary collapse
-
#lineno ⇒ Integer
readonly
The line number where the error occurred.
-
#production ⇒ Symbol
readonly
The current production.
-
#token ⇒ String
readonly
The invalid token which triggered the error.
Instance Method Summary collapse
-
#initialize(message, options = {}) ⇒ SyntaxError
constructor
Initializes a new syntax error instance.
Constructor Details
#initialize(message, options = {}) ⇒ SyntaxError
Initializes a new syntax error instance.
685 686 687 688 689 690 |
# File 'lib/rdf/turtle/reader.rb', line 685 def initialize(, = {}) @production = [:production] @token = [:token] @lineno = [:lineno] || (@token.lineno if @token.respond_to?(:lineno)) super(.to_s) end |
Instance Attribute Details
#lineno ⇒ Integer (readonly)
The line number where the error occurred.
675 676 677 |
# File 'lib/rdf/turtle/reader.rb', line 675 def lineno @lineno end |
#production ⇒ Symbol (readonly)
The current production.
663 664 665 |
# File 'lib/rdf/turtle/reader.rb', line 663 def production @production end |
#token ⇒ String (readonly)
The invalid token which triggered the error.
669 670 671 |
# File 'lib/rdf/turtle/reader.rb', line 669 def token @token end |