com.google.javascript.jscomp
Class AstValidator
java.lang.Object
com.google.javascript.jscomp.AstValidator
- All Implemented Interfaces:
- CompilerPass
public class AstValidator
- extends Object
- implements CompilerPass
This class walks the AST and validates that the structure is correct.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AstValidator
public AstValidator(AstValidator.ViolationHandler handler)
AstValidator
public AstValidator()
process
public void process(Node externs,
Node root)
- Description copied from interface:
CompilerPass
- Process the JS with root node root.
Can modify the contents of each Node tree
- Specified by:
process
in interface CompilerPass
- Parameters:
externs
- Top of external JS treeroot
- Top of JS tree
validateRoot
public void validateRoot(Node n)
validateCodeRoot
public void validateCodeRoot(Node n)
validateScript
public void validateScript(Node n)
validateStatement
public void validateStatement(Node n)
validateExpression
public void validateExpression(Node n)