public abstract class AbstractAnyPathSeCheck extends SeCheck
| Constructor and Description |
|---|
AbstractAnyPathSeCheck() |
| Modifier and Type | Method and Description |
|---|---|
<T extends Issue> |
addIssue(T issue) |
PreciseIssue |
addIssue(Tree tree,
String message)
Subclasses should not use this function, as this function bypasses the
non-duplication mechanism implemented by this class.
|
Optional<PreciseIssue> |
addUniqueIssue(Tree tree,
String message)
Creates an issue for the specified tree and message, then adds the issue
to the list of issues.
|
Optional<PreciseIssue> |
addUniqueIssue(Tree tree,
String message,
IssueLocation... secondaryLocations)
Same contract as method
addIssue(Tree, String). |
Optional<PreciseIssue> |
addUniqueIssue(Tree tree,
String message,
Tree... secondaryLocations)
Same contract as method
addIssue(Tree, String). |
boolean |
alreadyHasIssueOn(Tree tree)
Returns
true if an issue has already been reported for the specified tree. |
void |
doStartOfExecution(Scope functionScope)
Override this method to perform actions before the start of execution.
|
void |
startOfExecution(Scope functionScope) |
addLineIssue, afterBlockElement, beforeBlockElement, checkConditions, cleanupAndStartFileAnalysis, endOfExecution, endOfFile, getContext, scanFile, setContext, startOfFile, toStringpublic final void startOfExecution(Scope functionScope)
startOfExecution in class SeCheckpublic void doStartOfExecution(Scope functionScope)
functionScope - scope corresponding to the function which will be executedpublic final PreciseIssue addIssue(Tree tree, String message)
addUniqueIssue(org.sonar.plugins.javascript.api.tree.Tree, java.lang.String) methods.addIssue in interface JavaScriptCheckaddIssue in class SeCheckpublic final <T extends Issue> T addIssue(T issue)
addIssue in interface JavaScriptCheckaddIssue in class SeCheckpublic Optional<PreciseIssue> addUniqueIssue(Tree tree, String message)
public Optional<PreciseIssue> addUniqueIssue(Tree tree, String message, Tree... secondaryLocations)
addIssue(Tree, String).public Optional<PreciseIssue> addUniqueIssue(Tree tree, String message, IssueLocation... secondaryLocations)
addIssue(Tree, String).public boolean alreadyHasIssueOn(Tree tree)
true if an issue has already been reported for the specified tree.
This method does not have to be invoked prior to invoking method addUniqueIssue(org.sonar.plugins.javascript.api.tree.Tree, java.lang.String): this
method is just an optimization tool that allows subclasses not to perform useless operations
when an issue has already been reported.Copyright © 2011–2017 SonarSource and Eriks Nukis. All rights reserved.