Exception: Antlr4ruby::LexerNoViableAltException
Instance Method Summary
collapse
#get_ctx, #get_expected_tokens, #get_offending_state, #get_offending_token, #get_recognizer, #set_offending_state, #set_offending_token
Constructor Details
#initialize(lexer, input, start_index, dead_end_configs) ⇒ LexerNoViableAltException
Returns a new instance of LexerNoViableAltException.
5
6
7
8
|
# File 'lib/antlr4ruby/exception/lexer_no_viable_alt_exception.rb', line 5
def initialize(lexer, input, start_index, dead_end_configs)
super(lexer, input, nil )
@start_index, @dead_end_configs = start_index, dead_end_configs
end
|
Instance Method Details
#get_dead_end_configs ⇒ Object
14
15
16
|
# File 'lib/antlr4ruby/exception/lexer_no_viable_alt_exception.rb', line 14
def get_dead_end_configs
@dead_end_configs
end
|
22
23
24
|
# File 'lib/antlr4ruby/exception/lexer_no_viable_alt_exception.rb', line 22
def get_input_stream
super
end
|
#get_start_index ⇒ Object
18
19
20
|
# File 'lib/antlr4ruby/exception/lexer_no_viable_alt_exception.rb', line 18
def get_start_index
@start_index
end
|
#to_s ⇒ Object
26
27
28
29
30
31
32
|
# File 'lib/antlr4ruby/exception/lexer_no_viable_alt_exception.rb', line 26
def to_s
symbol = ''
if start_index >= 0 && start_index < get_input_stream.size
symbol = get_input_stream.get_text(start_index..start_index)
end
"#{self.class.name}(#{symbol})"
end
|