From ed61012f95cefae8d03260f506ffe34bc19bd90c Mon Sep 17 00:00:00 2001 From: Reinier Zwitserloot Date: Mon, 18 Feb 2013 21:41:07 +0100 Subject: whoops, belated push and fixes to the documentation of onX --- website/features/Constructor.html | 2 +- website/features/GetterSetter.html | 2 +- website/features/experimental/Value.html | 2 +- website/features/experimental/Wither.html | 2 +- website/features/experimental/index.html | 10 ++-- website/features/experimental/onX.html | 88 +++++++++++++++++++++++++++++++ website/features/onX.html | 71 ------------------------- 7 files changed, 98 insertions(+), 79 deletions(-) create mode 100644 website/features/experimental/onX.html delete mode 100644 website/features/onX.html (limited to 'website') diff --git a/website/features/Constructor.html b/website/features/Constructor.html index 051d730e..cdd5b4e2 100644 --- a/website/features/Constructor.html +++ b/website/features/Constructor.html @@ -35,7 +35,7 @@ Such a static factory method will infer generics, unlike a normal constructor. This means your API users get write MapEntry.of("foo", 5) instead of the much longer new MapEntry<String, Integer>("foo", 5).

- To put annotations on the generated constructor, you can use onConstructor={@AnnotationsHere}. For more details see the documentation on the onX feature. + To put annotations on the generated constructor, you can use onConstructor=@_({@AnnotationsHere}), but be careful; this is an experimental feature. For more details see the documentation on the onX feature.

Static fields are skipped by these annotations. Also, a @java.beans.ConstructorProperties annotation is added for all constructors with at least 1 argument, which allows bean editor tools to call the generated constructors. @ConstructorProperties is now in Java 1.6, which means that if your code is intended for diff --git a/website/features/GetterSetter.html b/website/features/GetterSetter.html index dde3456b..03704119 100644 --- a/website/features/GetterSetter.html +++ b/website/features/GetterSetter.html @@ -29,7 +29,7 @@ You can always manually disable getter/setter generation for any field by using the special AccessLevel.NONE access level. This lets you override the behaviour of a @Getter, @Setter or @Data annotation on a class.

- To put annotations on the generated method, you can use onMethod={@AnnotationsHere}; to put annotations on the only parameter of a generated setter method, you can use onParam={@AnnotationsHere}. For more details see the documentation on the onX feature. + To put annotations on the generated method, you can use onMethod=@_({@AnnotationsHere}); to put annotations on the only parameter of a generated setter method, you can use onParam=@_({@AnnotationsHere}). Be careful though! This is an experimental feature. For more details see the documentation on the onX feature.

diff --git a/website/features/experimental/Value.html b/website/features/experimental/Value.html index a82808e2..fb726d7b 100644 --- a/website/features/experimental/Value.html +++ b/website/features/experimental/Value.html @@ -68,7 +68,7 @@
diff --git a/website/features/experimental/Wither.html b/website/features/experimental/Wither.html index b0700aab..da2156cd 100644 --- a/website/features/experimental/Wither.html +++ b/website/features/experimental/Wither.html @@ -45,7 +45,7 @@ @Wither(level = AccessLevel.PROTECTED). Also like @Setter, you can also put a @Wither annotation on a type, which means a 'wither' is generated for each field (even non-final fields).

- To put annotations on the generated method, you can use onMethod={@AnnotationsHere}; to put annotations on the only parameter of this method, you can use onParam={@AnnotationsHere}. For more details see the documentation on the onX feature. + To put annotations on the generated method, you can use onMethod=@_({@AnnotationsHere}); to put annotations on the only parameter of a generated wither method, you can use onParam=@_({@AnnotationsHere}). Be careful though! This is an experimental feature. For more details see the documentation on the onX feature.

diff --git a/website/features/experimental/index.html b/website/features/experimental/index.html index acbbdbf6..24fbb541 100644 --- a/website/features/experimental/index.html +++ b/website/features/experimental/index.html @@ -24,14 +24,16 @@
@Accessors
A more fluent API for getters and setters.
-
@ExtensionMethod
+
@ExtensionMethod
Annoying API? Fix it yourself: Add new methods to existing types!
-
@FieldDefaults
+
@FieldDefaults
New default field modifiers for the 21st century.
-
@Wither
+
@Wither
Immutable 'setters' - methods that create a clone but with one changed field.
-
@Value
+
@Value
Immutable classes made very easy.
+
onMethod= / onConstructor= / onParam
+
Sup dawg, we heard you like annotations, so we put annotations in your annotations so you can annotate while you're annotating.