public abstract static class ConformanceRules.AbstractRule extends java.lang.Object implements CheckConformance.Rule
| Constructor and Description |
|---|
AbstractRule(AbstractCompiler compiler,
Requirement requirement) |
| Modifier and Type | Method and Description |
|---|---|
void |
check(NodeTraversal t,
Node n)
Perform conformance check
|
protected abstract ConformanceRules.ConformanceResult |
checkConformance(NodeTraversal t,
Node n) |
protected void |
report(Node n,
ConformanceRules.ConformanceResult result)
Report a conformance warning for the given node.
|
protected boolean |
tsIsWhitelisted() |
public AbstractRule(AbstractCompiler compiler, Requirement requirement) throws CheckConformance.InvalidRequirementSpec
protected boolean tsIsWhitelisted()
protected abstract ConformanceRules.ConformanceResult checkConformance(NodeTraversal t, Node n)
public final void check(NodeTraversal t, Node n)
CheckConformance.Rulecheck in interface CheckConformance.Ruleprotected void report(Node n, ConformanceRules.ConformanceResult result)
n - The node representing the violating code.result - The result representing the confidence of the violation.Copyright © 2009-2020 Google. All Rights Reserved.