diff options
Diffstat (limited to 'src/lombok/javac/handlers/HandlePrintAST.java')
-rw-r--r-- | src/lombok/javac/handlers/HandlePrintAST.java | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/lombok/javac/handlers/HandlePrintAST.java b/src/lombok/javac/handlers/HandlePrintAST.java new file mode 100644 index 00000000..23f4c6d6 --- /dev/null +++ b/src/lombok/javac/handlers/HandlePrintAST.java @@ -0,0 +1,18 @@ +package lombok.javac.handlers; + +import org.mangosdk.spi.ProviderFor; + +import com.sun.tools.javac.tree.JCTree.JCAnnotation; + +import lombok.core.AnnotationValues; +import lombok.core.PrintAST; +import lombok.javac.JavacASTVisitor; +import lombok.javac.JavacAnnotationHandler; +import lombok.javac.JavacAST.Node; + +@ProviderFor(JavacAnnotationHandler.class) +public class HandlePrintAST implements JavacAnnotationHandler<PrintAST> { + @Override public void handle(AnnotationValues<PrintAST> annotation, JCAnnotation ast, Node annotationNode) { + annotationNode.up().traverse(new JavacASTVisitor.JavacASTPrinter()); + } +} |