Groovy Documentation

org.codehaus.groovy.grails.compiler.injection
[Java] Class ArtefactTypeAstTransformation

java.lang.Object
  org.codehaus.groovy.grails.compiler.injection.AbstractArtefactTypeAstTransformation
      org.codehaus.groovy.grails.compiler.injection.ArtefactTypeAstTransformation

@org.codehaus.groovy.transform.GroovyASTTransformation(phase = CompilePhase.CANONICALIZATION)
public class ArtefactTypeAstTransformation
extends AbstractArtefactTypeAstTransformation

A transformation used to apply transformers to classes not located in Grails directory structure. For example any class can be annotated with @Artefact("Controller") to make it into a controller no matter what the location.

Authors:
Graeme Rocher
Since:
2.0


Method Summary
static void doPerformInjectionOnArtefactType(org.codehaus.groovy.control.SourceUnit sourceUnit, org.codehaus.groovy.ast.ClassNode cNode, java.lang.String artefactType)

static java.util.List findInjectors(java.lang.String artefactType, ClassInjector[] classInjectors)

static boolean hasArtefactType(java.lang.String artefactType, GrailsArtefactClassInjector gace)

static void performInjection(org.codehaus.groovy.control.SourceUnit sourceUnit, org.codehaus.groovy.ast.ClassNode cNode, java.util.Collection injectors)

void performInjectionOnArtefactType(org.codehaus.groovy.control.SourceUnit sourceUnit, org.codehaus.groovy.ast.ClassNode cNode, java.lang.String artefactType)

void visit(org.codehaus.groovy.ast.ASTNode[] astNodes, org.codehaus.groovy.control.SourceUnit sourceUnit)

 
Methods inherited from class AbstractArtefactTypeAstTransformation
performInjectionOnArtefactType
 
Methods inherited from class java.lang.Object
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Method Detail

doPerformInjectionOnArtefactType

public static void doPerformInjectionOnArtefactType(org.codehaus.groovy.control.SourceUnit sourceUnit, org.codehaus.groovy.ast.ClassNode cNode, java.lang.String artefactType)


findInjectors

public static java.util.List findInjectors(java.lang.String artefactType, ClassInjector[] classInjectors)


hasArtefactType

public static boolean hasArtefactType(java.lang.String artefactType, GrailsArtefactClassInjector gace)


performInjection

public static void performInjection(org.codehaus.groovy.control.SourceUnit sourceUnit, org.codehaus.groovy.ast.ClassNode cNode, java.util.Collection injectors)


performInjectionOnArtefactType

public void performInjectionOnArtefactType(org.codehaus.groovy.control.SourceUnit sourceUnit, org.codehaus.groovy.ast.ClassNode cNode, java.lang.String artefactType)


visit

public void visit(org.codehaus.groovy.ast.ASTNode[] astNodes, org.codehaus.groovy.control.SourceUnit sourceUnit)


 

Groovy Documentation