Package org.sonar.python.checks.regex
Class GroupReplacementCheck
- java.lang.Object
-
- org.sonar.plugins.python.api.PythonSubscriptionCheck
-
- org.sonar.python.checks.regex.AbstractRegexCheck
-
- org.sonar.python.checks.regex.GroupReplacementCheck
-
- All Implemented Interfaces:
PythonCheck,SubscriptionCheck
public class GroupReplacementCheck extends AbstractRegexCheck
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.sonar.plugins.python.api.PythonCheck
PythonCheck.CheckScope, PythonCheck.PreciseIssue
-
Nested classes/interfaces inherited from interface org.sonar.plugins.python.api.SubscriptionCheck
SubscriptionCheck.Context
-
-
Field Summary
-
Fields inherited from class org.sonar.python.checks.regex.AbstractRegexCheck
regexContext, reportedRegexTrees
-
-
Constructor Summary
Constructors Constructor Description GroupReplacementCheck()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckRegex(org.sonarsource.analyzer.commons.regex.RegexParseResult regexParseResult, CallExpression regexFunctionCall)protected Map<String,Integer>lookedUpFunctions()Should return a map whose keys are the functions the check is interested in, and the values are the position of the flags parameter.-
Methods inherited from class org.sonar.python.checks.regex.AbstractRegexCheck
addIssue, initialize, mapPythonFlag
-
Methods inherited from class org.sonar.plugins.python.api.PythonSubscriptionCheck
leaveFile, scanFile
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.sonar.plugins.python.api.PythonCheck
scanWithoutParsing, scope
-
-
-
-
Method Detail
-
lookedUpFunctions
protected Map<String,Integer> lookedUpFunctions()
Description copied from class:AbstractRegexCheckShould return a map whose keys are the functions the check is interested in, and the values are the position of the flags parameter. Set the position of the flags parameter tonullif there is none.- Overrides:
lookedUpFunctionsin classAbstractRegexCheck
-
checkRegex
public void checkRegex(org.sonarsource.analyzer.commons.regex.RegexParseResult regexParseResult, CallExpression regexFunctionCall)- Specified by:
checkRegexin classAbstractRegexCheck
-
-