Class SupersetAutomataChecker
- java.lang.Object
-
- org.sonarsource.analyzer.commons.regex.helpers.AbstractAutomataChecker
-
- org.sonarsource.analyzer.commons.regex.helpers.SupersetAutomataChecker
-
public class SupersetAutomataChecker extends AbstractAutomataChecker
-
-
Field Summary
-
Fields inherited from class org.sonarsource.analyzer.commons.regex.helpers.AbstractAutomataChecker
defaultAnswer
-
-
Constructor Summary
Constructors Constructor Description SupersetAutomataChecker(boolean defaultAnswer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleancheckAuto1AndAuto2Successors(SubAutomaton auto1, SubAutomaton auto2, boolean defaultAnswer, boolean hasConsumedInput)protected booleancheckAuto1Successors(SubAutomaton auto1, SubAutomaton auto2, boolean defaultAnswer, boolean hasConsumedInput)protected booleancheckAuto2Successors(SubAutomaton auto1, SubAutomaton auto2, boolean defaultAnswer, boolean hasConsumedInput)protected booleanneutralAnswer()The answer that should be returned when running into a cycle in the automaton.-
Methods inherited from class org.sonarsource.analyzer.commons.regex.helpers.AbstractAutomataChecker
check, check, clearCache
-
-
-
-
Method Detail
-
neutralAnswer
protected boolean neutralAnswer()
Description copied from class:AbstractAutomataCheckerThe answer that should be returned when running into a cycle in the automaton. This should be the neutral element with respect to the operation that's used to combine the results from multiple paths. That is, if there are multiple paths, one of whom is part of a cycle whereas the others are not, then the end result should just depend on the non-cyclic paths. Thus if the results are combined with "any", the neutral element should be false and for "all" it should be true.- Specified by:
neutralAnswerin classAbstractAutomataChecker
-
checkAuto1AndAuto2Successors
protected boolean checkAuto1AndAuto2Successors(SubAutomaton auto1, SubAutomaton auto2, boolean defaultAnswer, boolean hasConsumedInput)
- Specified by:
checkAuto1AndAuto2Successorsin classAbstractAutomataChecker
-
checkAuto1Successors
protected boolean checkAuto1Successors(SubAutomaton auto1, SubAutomaton auto2, boolean defaultAnswer, boolean hasConsumedInput)
- Specified by:
checkAuto1Successorsin classAbstractAutomataChecker
-
checkAuto2Successors
protected boolean checkAuto2Successors(SubAutomaton auto1, SubAutomaton auto2, boolean defaultAnswer, boolean hasConsumedInput)
- Specified by:
checkAuto2Successorsin classAbstractAutomataChecker
-
-