From ff306fa5d97a09d69332c76a33596bb053222855 Mon Sep 17 00:00:00 2001 From: Reinier Zwitserloot Date: Fri, 19 Jun 2009 16:24:10 +0200 Subject: Added initial support for the @Data annotation. Currently produces getters and setters only, not yet a constructor, toString, hashCode, or equals. HandleGetter and HandleSetter have been updated to handle static (theoretic; you can't put annotations on static fields normally). You can now make AnnotationValue objects using just an annotationNode and a target type, as well as check if a given annotationNode is likely to represent a target annotation type. This is in Javac and Eclipse classes. HandleGetter and HandleSetter can now be asked to make a getter/setter, and will grab access level off of a Getter/Setter annotation, if present. --- src/lombok/Data.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 src/lombok/Data.java (limited to 'src/lombok/Data.java') diff --git a/src/lombok/Data.java b/src/lombok/Data.java new file mode 100644 index 00000000..e985a28a --- /dev/null +++ b/src/lombok/Data.java @@ -0,0 +1,13 @@ +package lombok; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Target(ElementType.TYPE) +@Retention(RetentionPolicy.SOURCE) +public @interface Data { + String staticConstructor() default ""; + int hashCodePrime() default 31; +} -- cgit