Enum Class TransitionGuard.Kind
- All Implemented Interfaces:
Serializable,Comparable<TransitionGuard.Kind>,Constable
- Enclosing class:
TransitionGuard
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionTransition is entering the then-branch (the first alternative) of aConditionalBackReferenceGroup.Transition is entering the else-branch (the second alternative) of aConditionalBackReferenceGroup.Transition is entering a quantified expression that may match the empty string.Transition is leaving a quantified expression that may match the empty string and it is about to continue to what follows the loop.Transition is leaving a quantified expression.Transition is leaving a quantified expression without lower bound, i.e.Transition is leaving a quantified expression that may match the empty string.Transition represents a back-edge in the quantifier loop.Transition represents either a first entry into a quantified expression, or a back-edge in a quantifier loop without upper bound, i.e.Transition is passing a capture group boundary.Transition is leaving a group containing recursive back-references. -
Method Summary
Modifier and TypeMethodDescriptionstatic TransitionGuard.KindReturns the enum constant of this class with the specified name.static TransitionGuard.Kind[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
loop
Transition represents a back-edge in the quantifier loop. Check if the loop count is belowToken.Quantifier.getMax(), then increase loop count. -
loopInc
Transition represents either a first entry into a quantified expression, or a back-edge in a quantifier loop without upper bound, i.e. quantifiers whereToken.Quantifier.isInfiniteLoop()istrue. Just increase the loop count. -
exit
Transition is leaving a quantified expression. Check if the loop count is aboveToken.Quantifier.getMin(), then reset the loop count. -
exitReset
Transition is leaving a quantified expression without lower bound, i.e. quantifiers whereToken.Quantifier.getMin()== 0. Just reset the loop count. -
enterZeroWidth
Transition is entering a quantified expression that may match the empty string. Save the current index. -
exitZeroWidth
Transition is leaving a quantified expression that may match the empty string. Check if the current index is greater than the saved index. In the case of flavors in whichRegexFlavor.emptyChecksMonitorCaptureGroups(), also check if any capture groups were modified. -
escapeZeroWidth
Transition is leaving a quantified expression that may match the empty string and it is about to continue to what follows the loop. This is possible in flavors in whichRegexFlavor.failingEmptyChecksDontBacktrack()and only when the last iteration of the quantified expression fails the empty check (the check for the index and the state of capture groups tested byexitZeroWidth). -
updateCG
Transition is passing a capture group boundary. We need this information in order to implement the empty check test inexitZeroWidth, which, in the case of flavors in whichRegexFlavor.emptyChecksMonitorCaptureGroups(), where we need to monitor the state of capture groups in betweenenterZeroWidthandexitZeroWidth. -
updateRecursiveBackrefPointer
Transition is leaving a group containing recursive back-references. -
checkGroupMatched
Transition is entering the then-branch (the first alternative) of aConditionalBackReferenceGroup. The capture group identified byTransitionGuard.getGroupNumber(long)must be matched in order to proceed. -
checkGroupNotMatched
Transition is entering the else-branch (the second alternative) of aConditionalBackReferenceGroup. The capture group identified byTransitionGuard.getGroupNumber(long)must be *not* matched in order to proceed.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-