Package com.google.javascript.jscomp
Interface CheckConformance.Rule
-
- All Known Implementing Classes:
ConformanceRules.AbstractRule,ConformanceRules.BanCreateDom,ConformanceRules.BanCreateElement,ConformanceRules.BanExecCommand,ConformanceRules.BanForOf,ConformanceRules.BanGlobalVars,ConformanceRules.BannedEnhance,ConformanceRules.BanNullDeref,ConformanceRules.BanSetAttribute,ConformanceRules.BanStaticThis,ConformanceRules.BanThrowOfNonErrorTypes,ConformanceRules.BanUnknownDirectThisPropsReferences,ConformanceRules.BanUnknownThis,ConformanceRules.BanUnknownTypedClassPropsReferences,ConformanceRules.BanUnresolvedType,ConformanceRules.RequireUseStrict,ConformanceRules.StrictBanUnresolvedType
- Enclosing class:
- CheckConformance
public static interface CheckConformance.Rule
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidcheck(NodeTraversal t, Node n)Perform conformance checkdefault CheckConformance.PreconditiongetPrecondition()Return a precondition for this rule.
-
-
-
Method Detail
-
getPrecondition
@Nullable default CheckConformance.Precondition getPrecondition()
Return a precondition for this rule.This method will only be called once (per rule) during the creation of the CheckConformance pass. Therefore, the return must be constant.
Returning null means that there is no precondition. This is convenient, but can be a major performance hit.
-
check
void check(NodeTraversal t, Node n)
Perform conformance check
-
-