ParseTreePattern class

A pattern like {@code

Constructors

ParseTreePattern(ParseTreePatternMatcher matcher, String pattern, int patternRuleIndex, ParseTree patternTree)
Construct a new instance of the ParseTreePattern class.

Properties

hashCode int
The hash code for this object.
no setterinherited
matcher ParseTreePatternMatcher
Get the ParseTreePatternMatcher which created this tree pattern.
final
pattern String
Get the tree pattern in concrete syntax form.
final
patternRuleIndex int
Get the parser rule which serves as the outermost rule for the tree pattern.
final
patternTree ParseTree
Get the tree pattern as a ParseTree. The rule and token tags from the pattern are present in the parse tree as terminal nodes with a symbol of type RuleTagToken or TokenTagToken.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

match(ParseTree tree) ParseTreeMatch
Match a specific parse tree against this tree pattern.
matches(ParseTree tree) bool
Determine whether or not a parse tree matches this tree pattern.
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