Package org.sonar.java.regex.ast
Class RegexTree
- java.lang.Object
-
- org.sonar.java.regex.ast.AbstractRegexSyntaxElement
-
- org.sonar.java.regex.ast.RegexTree
-
- All Implemented Interfaces:
AutomatonState
,RegexSyntaxElement
- Direct Known Subclasses:
BackReferenceTree
,BoundaryTree
,CharacterClassTree
,CharacterTree
,DisjunctionTree
,DotTree
,EscapedCharacterClassTree
,GroupTree
,MiscEscapeSequenceTree
,RepetitionTree
,SequenceTree
public abstract class RegexTree extends AbstractRegexSyntaxElement implements AutomatonState
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
RegexTree.Kind
-
Nested classes/interfaces inherited from interface org.sonar.java.regex.ast.AutomatonState
AutomatonState.TransitionType
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
RegexTree(RegexSource source, IndexRange range, FlagSet activeFlags)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
accept(RegexVisitor visitor)
This method should only be called by RegexBaseVisitor (or other implementations of the RegexVisitor interface).FlagSet
activeFlags()
AutomatonState
continuation()
This will only return null when called on the end-of-regex stateboolean
is(RegexTree.Kind... kinds)
abstract RegexTree.Kind
kind()
void
setContinuation(AutomatonState continuation)
-
Methods inherited from class org.sonar.java.regex.ast.AbstractRegexSyntaxElement
getLocations, getRange, getSource, getText
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.sonar.java.regex.ast.AutomatonState
incomingTransitionType, successors
-
-
-
-
Constructor Detail
-
RegexTree
protected RegexTree(RegexSource source, IndexRange range, FlagSet activeFlags)
-
-
Method Detail
-
activeFlags
@Nonnull public FlagSet activeFlags()
- Specified by:
activeFlags
in interfaceAutomatonState
-
accept
public abstract void accept(RegexVisitor visitor)
This method should only be called by RegexBaseVisitor (or other implementations of the RegexVisitor interface). Do not call this method to invoke a visitor, use visitor.visit(tree) instead.
-
kind
public abstract RegexTree.Kind kind()
-
is
public boolean is(RegexTree.Kind... kinds)
-
continuation
@Nonnull public AutomatonState continuation()
Description copied from interface:AutomatonState
This will only return null when called on the end-of-regex state- Specified by:
continuation
in interfaceAutomatonState
-
setContinuation
public void setContinuation(AutomatonState continuation)
-
-