Exception: SPARQL::Grammar::Parser::Error
- Inherits:
-
StandardError
- Object
- StandardError
- SPARQL::Grammar::Parser::Error
- Defined in:
- lib/sparql/grammar/parser.rb
Overview
Raised for errors during parsing.
Instance Attribute Summary (collapse)
-
- (String) input
readonly
The input string associated with the error.
-
- (Integer) lineno
readonly
The line number where the error occurred.
-
- (Integer) position
readonly
Position within line of error.
-
- (String) production
readonly
The grammar production where the error was found.
Instance Method Summary (collapse)
-
- (Error) initialize(message, options = {})
constructor
Initializes a new lexer error instance.
Constructor Details
- (Error) initialize(message, options = {})
Initializes a new lexer error instance.
1341 1342 1343 1344 1345 1346 1347 |
# File 'lib/sparql/grammar/parser.rb', line 1341 def initialize(, = {}) @input = [:input] @production = [:production] @lineno = [:lineno] @position = [:position] super(.to_s) end |
Instance Attribute Details
- (String) input (readonly)
The input string associated with the error.
1312 1313 1314 |
# File 'lib/sparql/grammar/parser.rb', line 1312 def input @input end |
- (Integer) lineno (readonly)
The line number where the error occurred.
1324 1325 1326 |
# File 'lib/sparql/grammar/parser.rb', line 1324 def lineno @lineno end |
- (Integer) position (readonly)
Position within line of error.
1330 1331 1332 |
# File 'lib/sparql/grammar/parser.rb', line 1330 def position @position end |
- (String) production (readonly)
The grammar production where the error was found.
1318 1319 1320 |
# File 'lib/sparql/grammar/parser.rb', line 1318 def production @production end |