Package com.google.javascript.jscomp
Class ShowByPathWarningsGuard
- java.lang.Object
-
- com.google.javascript.jscomp.WarningsGuard
-
- com.google.javascript.jscomp.ShowByPathWarningsGuard
-
- All Implemented Interfaces:
java.io.Serializable
public final class ShowByPathWarningsGuard extends WarningsGuard
Control whether warnings should be restricted or suppressed for specified paths.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ShowByPathWarningsGuard.ShowType
Controls whether warnings should be restricted to a specified path or suppressed within the specified path.-
Nested classes/interfaces inherited from class com.google.javascript.jscomp.WarningsGuard
WarningsGuard.Priority
-
-
Constructor Summary
Constructors Constructor Description ShowByPathWarningsGuard(java.lang.String checkWarningsOnlyForPath)
ShowByPathWarningsGuard(java.lang.String[] checkWarningsOnlyForPath)
ShowByPathWarningsGuard(java.lang.String[] paths, ShowByPathWarningsGuard.ShowType showType)
ShowByPathWarningsGuard(java.lang.String path, ShowByPathWarningsGuard.ShowType showType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected int
getPriority()
The priority in which warnings guards are applied.CheckLevel
level(JSError error)
Returns a new check level for a given error.-
Methods inherited from class com.google.javascript.jscomp.WarningsGuard
mustRunChecks
-
-
-
-
Constructor Detail
-
ShowByPathWarningsGuard
public ShowByPathWarningsGuard(java.lang.String checkWarningsOnlyForPath)
-
ShowByPathWarningsGuard
public ShowByPathWarningsGuard(java.lang.String[] checkWarningsOnlyForPath)
-
ShowByPathWarningsGuard
public ShowByPathWarningsGuard(java.lang.String path, ShowByPathWarningsGuard.ShowType showType)
-
ShowByPathWarningsGuard
public ShowByPathWarningsGuard(java.lang.String[] paths, ShowByPathWarningsGuard.ShowType showType)
-
-
Method Detail
-
level
public CheckLevel level(JSError error)
Description copied from class:WarningsGuard
Returns a new check level for a given error.`null` means that this guard does not know what to do with the error. `null` can be used it chain multiple guards; if current guard returns null, then the next in the chain should process it.
- Specified by:
level
in classWarningsGuard
- Parameters:
error
- a reported error.- Returns:
- what level given error should have.
-
getPriority
protected int getPriority()
Description copied from class:WarningsGuard
The priority in which warnings guards are applied. Lower means the guard will be applied sooner. Expressed on a scale of 1 to 100.- Overrides:
getPriority
in classWarningsGuard
-
-