FailedPredicateException class
A semantic predicate failed during validation. Validation of predicates occurs when normally parsing the alternative just like matching a token. Disambiguating predicate evaluation occurs when we test a predicate during prediction.
- Inheritance
-
- Object
- Error
- StateError
- RecognitionException<
IntStream> - FailedPredicateException
Constructors
- FailedPredicateException(Parser recognizer, [String? predicate, String? message])
Properties
- ctx → RuleContext?
-
Gets the RuleContext at the time this exception was thrown.
finalinherited
- expectedTokens → IntervalSet?
-
Gets the set of input symbols which could potentially follow the
previously matched symbol at the time this exception was thrown.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- inputStream → IntStream
-
Gets the input stream which is the symbol source for the recognizer where
this exception was thrown.
finalinherited
- message → String
-
finalinherited
- offendingState ↔ int
-
Get the ATN state number the parser was in at the time the error
occurred. For NoViableAltException and
LexerNoViableAltException exceptions, this is the
DecisionState number. For others, it is the state whose outgoing
edge we couldn't match.
getter/setter pairinherited
- offendingToken ↔ Token
-
The current Token when an error occurred. Since not all streams
support accessing symbols by index, we have to track the Token
instance itself.
getter/setter pairinherited
- predicate → String?
-
final
- predIndex ↔ int?
-
getter/setter pair
-
recognizer
→ Recognizer<
ATNSimulator> ? -
Gets the Recognizer where this exception occurred.
finalinherited
- ruleIndex ↔ int?
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stackTrace → StackTrace?
-
The stack trace at the point where this error was first thrown.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
formatMessage(
String? predicate, String? message) → String