Just renamed some parameters to more sensical names.

This commit is contained in:
Reinier Zwitserloot committed 2009-06-17 20:54:25 +02:00
1 parent 981e7db354
commit 5bdfa539f2
2 files changed
+6 -6

No files matched your search

+1 -1
View File
@@ -7,5 +7,5 @@ import lombok.core.AnnotationValues;
import com.sun.tools.javac.tree.JCTree.JCAnnotation;
public interface JavacAnnotationHandler<T extends Annotation> {
void handle(AnnotationValues<T> annotation, JCAnnotation ast, JavacAST.Node annotedElement);
void handle(AnnotationValues<T> annotation, JCAnnotation ast, JavacAST.Node annotationNode);
}
+5 -5
View File
@@ -25,19 +25,19 @@ import com.sun.tools.javac.util.Name;
@ProviderFor(JavacAnnotationHandler.class)
public class HandleGetter implements JavacAnnotationHandler<Getter> {
@Override public void handle(AnnotationValues<Getter> annotation, JCAnnotation ast, JavacAST.Node node) {
if ( node.up().getKind() != Kind.FIELD ) {
node.addError("@Getter is only supported on a field.");
@Override public void handle(AnnotationValues<Getter> annotation, JCAnnotation ast, JavacAST.Node annotationNode) {
if ( annotationNode.up().getKind() != Kind.FIELD ) {
annotationNode.addError("@Getter is only supported on a field.");
return;
}
Getter getter = annotation.getInstance();
JCClassDecl javacClassTree = (JCClassDecl) node.up().up().get();
JCClassDecl javacClassTree = (JCClassDecl) annotationNode.up().up().get();
int access = toJavacModifier(getter.value());
MethodTree getterMethod = createGetter(access, node.up(), node.getTreeMaker());
MethodTree getterMethod = createGetter(access, annotationNode.up(), annotationNode.getTreeMaker());
javacClassTree.defs = javacClassTree.defs.append((JCTree)getterMethod);
}