diff options
author | Roel Spilker <r.spilker@gmail.com> | 2014-03-26 22:33:00 +0100 |
---|---|---|
committer | Roel Spilker <r.spilker@gmail.com> | 2014-03-26 22:33:00 +0100 |
commit | d41ef4bf8370a16121d00146f905e866ac7e5a0b (patch) | |
tree | 614ca16c4187d7ed7adb50625230a80bdef4b68b /website | |
parent | 4d24542dac058fcd7c341f9d17c4e8170a8d83a2 (diff) | |
download | lombok-d41ef4bf8370a16121d00146f905e866ac7e5a0b.tar.gz lombok-d41ef4bf8370a16121d00146f905e866ac7e5a0b.tar.bz2 lombok-d41ef4bf8370a16121d00146f905e866ac7e5a0b.zip |
[i659] suppression of @ConstructorProperties should use config instead. Also modified all onX examples to use two underscores.
Diffstat (limited to 'website')
-rw-r--r-- | website/features/Constructor.html | 2 | ||||
-rw-r--r-- | website/features/GetterSetter.html | 2 | ||||
-rw-r--r-- | website/features/experimental/Wither.html | 2 | ||||
-rw-r--r-- | website/features/experimental/onX.html | 4 |
4 files changed, 5 insertions, 5 deletions
diff --git a/website/features/Constructor.html b/website/features/Constructor.html index 272df06e..c7e40dfb 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 <code>MapEntry.of("foo", 5)</code> instead of the much longer <code>new MapEntry<String, Integer>("foo", 5)</code>. </p><p> - To put annotations on the generated constructor, you can use <code>onConstructor=@_({@AnnotationsHere})</code>, but be careful; this is an experimental feature. For more details see the documentation on the <a href="experimental/onX.html">onX</a> feature. + To put annotations on the generated constructor, you can use <code>onConstructor=@__({@AnnotationsHere})</code>, but be careful; this is an experimental feature. For more details see the documentation on the <a href="experimental/onX.html">onX</a> feature. </p><p> Static fields are skipped by these annotations. Also, a <code>@java.beans.ConstructorProperties</code> annotation is added for all constructors with at least 1 argument, which allows bean editor tools to call the generated constructors. <code>@ConstructorProperties</code> 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 7e2ff226..2e39e1ad 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 <code>AccessLevel.NONE</code> access level. This lets you override the behaviour of a <code>@Getter</code>, <code>@Setter</code> or <code>@Data</code> annotation on a class. </p><p> - To put annotations on the generated method, you can use <code>onMethod=@_({@AnnotationsHere})</code>; to put annotations on the only parameter of a generated setter method, you can use <code>onParam=@_({@AnnotationsHere})</code>. Be careful though! This is an experimental feature. For more details see the documentation on the <a href="experimental/onX.html">onX</a> feature. + To put annotations on the generated method, you can use <code>onMethod=@__({@AnnotationsHere})</code>; to put annotations on the only parameter of a generated setter method, you can use <code>onParam=@__({@AnnotationsHere})</code>. Be careful though! This is an experimental feature. For more details see the documentation on the <a href="experimental/onX.html">onX</a> feature. </p><p> <em>NEW in lombok v1.12.0:</em> javadoc on the field will now be copied to generated getters and setters. Normally, all text is copied, and <code>@return</code> is <em>moved</em> to the getter, whilst <code>@param</code> lines are <em>moved</em> to the setter. Moved means: Deleted from the field's javadoc. It is also possible to define unique text for each getter/setter. To do that, you create a 'section' named <code>GETTER</code> and/or <code>SETTER</code>. A section is a line in your javadoc containing 2 or more dashes, then the text 'GETTER' or 'SETTER', followed by 2 or more dashes, and nothing else on the line. If you use sections, <code>@return</code> and <code>@param</code> stripping for that section is no longer done (move the <code>@return</code> or <code>@param</code> line into the section). </p> diff --git a/website/features/experimental/Wither.html b/website/features/experimental/Wither.html index b334cd7c..46d3b08b 100644 --- a/website/features/experimental/Wither.html +++ b/website/features/experimental/Wither.html @@ -45,7 +45,7 @@ <code>@Wither(level = AccessLevel.PROTECTED)</code>. Also like <a href="../GetterSetter.html"><code>@Setter</code></a>, you can also put a <code>@Wither</code> annotation on a type, which means a 'wither' is generated for each field (even non-final fields). </p><p> - To put annotations on the generated method, you can use <code>onMethod=@_({@AnnotationsHere})</code>; to put annotations on the only parameter of a generated wither method, you can use <code>onParam=@_({@AnnotationsHere})</code>. Be careful though! This is an experimental feature. For more details see the documentation on the <a href="onX.html">onX</a> feature. + To put annotations on the generated method, you can use <code>onMethod=@__({@AnnotationsHere})</code>; to put annotations on the only parameter of a generated wither method, you can use <code>onParam=@__({@AnnotationsHere})</code>. Be careful though! This is an experimental feature. For more details see the documentation on the <a href="onX.html">onX</a> feature. </p><p> <em>NEW in lombok v1.12.0:</em> javadoc on the field will now be copied to generated withers. Normally, all text is copied, and <code>@param</code> is <em>moved</em> to the wither, whilst <code>@return</code> lines are stripped from the wither's javadoc. Moved means: Deleted from the field's javadoc. It is also possible to define unique text for the wither's javadoc. To do that, you create a 'section' named <code>WITHER</code>. A section is a line in your javadoc containing 2 or more dashes, then the text 'WITHER', followed by 2 or more dashes, and nothing else on the line. If you use sections, <code>@return</code> and <code>@param</code> stripping / copying for that section is no longer done (move the <code>@param</code> line into the section). </p> diff --git a/website/features/experimental/onX.html b/website/features/experimental/onX.html index 66b0164f..530d98a4 100644 --- a/website/features/experimental/onX.html +++ b/website/features/experimental/onX.html @@ -42,7 +42,7 @@ </p><p> <code>@Setter</code> and <code>@Wither</code> support <code>onParam</code> in addition to <code>onMethod</code>; annotations listed will be put on the only parameter that the generated method has. </p><p> - The syntax is a little strange; to use any of the 3 <code>onX</code> features, you must wrap the annotations to be applied to the constructor / method / parameter in <code>@_(@AnnotationGoesHere)</code>. To apply multiple annotations, use <code>@_({@Annotation1, @Annotation2})</code>. The annotations can themselves obviously have parameters as well. + The syntax is a little strange; to use any of the 3 <code>onX</code> features, you must wrap the annotations to be applied to the constructor / method / parameter in <code>@__(@AnnotationGoesHere)</code>. To apply multiple annotations, use <code>@__({@Annotation1, @Annotation2})</code>. The annotations can themselves obviously have parameters as well. </p> </div> <div class="snippets"> @@ -60,7 +60,7 @@ <div class="overview"> <h3>Small print</h3><div class="smallprint"> <p> - The reason of the weird syntax is to make this feature work in javac 7 compilers; the <code>@_</code> type is an annotation reference to the annotation type <code>_</code> (underscore) which doesn't actually exist; this makes javac 7 delay aborting the compilation process due to an error because it is possible an annotation processor will later create the <code>_</code> type. Instead, lombok applies the annotations and removes the references so that the error will never actually occur. The point is: The <code>_</code> type <em>must not exist</em>, otherwise the feature does not work. In the rare case that the <code>_</code> type does exist (and is imported or in the package), you can simply add more underscores. Technically any non-existent type would work, but to maintain consistency and readability and catch erroneous use, lombok considers it an error if the 'wrapper' annotation is anything but a series of underscores. + The reason of the weird syntax is to make this feature work in javac 7 compilers; the <code>@__</code> type is an annotation reference to the annotation type <code>_</code> (underscore) which doesn't actually exist; this makes javac 7 delay aborting the compilation process due to an error because it is possible an annotation processor will later create the <code>_</code> type. Instead, lombok applies the annotations and removes the references so that the error will never actually occur. The point is: The <code>_</code> type <em>must not exist</em>, otherwise the feature does not work. In the rare case that the <code>_</code> type does exist (and is imported or in the package), you can simply add more underscores. Technically any non-existent type would work, but to maintain consistency and readability and catch erroneous use, lombok considers it an error if the 'wrapper' annotation is anything but a series of underscores. </p><p> To reiterate: This feature can disappear at any time; if you use this feature, be prepared to adjust your code when we find a nicer way of implementing this feature, or, if a future version of javac forces us to remove this feature entirely with no alternative. </p><p> |