public class StaticCompileTransformation extends StaticTypesTransformation
CompileStatic
transformation.compilationUnit, STATIC_ERROR_PREFIX
Constructor and Description |
---|
StaticCompileTransformation() |
Modifier and Type | Method and Description |
---|---|
protected StaticTypeCheckingVisitor |
newVisitor(SourceUnit unit,
ClassNode node)
Allows subclasses to provide their own visitor.
|
void |
visit(ASTNode[] nodes,
SourceUnit source)
The method is invoked when an AST Transformation is active.
|
addTypeCheckingExtensions, setCompilationUnit
public void visit(ASTNode[] nodes, SourceUnit source)
ASTTransformation
visit
in interface ASTTransformation
visit
in class StaticTypesTransformation
nodes
- The ASTnodes when the call was triggered. Element 0 is the AnnotationNode that triggered this
annotation to be activated. Element 1 is the AnnotatedNode decorated, such as a MethodNode or ClassNode. For
global transformations it is usually safe to ignore this parameter.source
- The source unit being compiled. The source unit may contain several classes. For global transformations,
information about the AST can be retrieved from this object.protected StaticTypeCheckingVisitor newVisitor(SourceUnit unit, ClassNode node)
StaticTypesTransformation
newVisitor
in class StaticTypesTransformation
unit
- the source unitnode
- the current classnode