|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.groovy.ast.CodeVisitorSupport
org.codehaus.groovy.ast.ClassCodeVisitorSupport
groovy.grape.GrabAnnotationTransformation
public class GrabAnnotationTransformation
Transformation for declarative dependency management.
Constructor Summary | |
---|---|
GrabAnnotationTransformation()
|
Method Summary | |
---|---|
SourceUnit |
getSourceUnit()
|
void |
setCompilationUnit(CompilationUnit compilationUnit)
|
void |
visit(ASTNode[] nodes,
SourceUnit source)
The method is invoked when an AST Transformation is active. |
void |
visitAnnotations(AnnotatedNode node)
Adds the annotation to the internal target list if a match is found. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GrabAnnotationTransformation()
Method Detail |
---|
public SourceUnit getSourceUnit()
getSourceUnit
in class ClassCodeVisitorSupport
public void setCompilationUnit(CompilationUnit compilationUnit)
setCompilationUnit
in interface CompilationUnitAware
public void visit(ASTNode[] nodes, SourceUnit source)
ASTTransformation
visit
in interface ASTTransformation
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.public void visitAnnotations(AnnotatedNode node)
visitAnnotations
in class ClassCodeVisitorSupport
node
- the AST node we are processing
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |