aboutsummaryrefslogtreecommitdiff
path: root/test/transform/resource/after-delombok
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@zwitserloot.com>2013-07-16 00:51:31 +0200
committerReinier Zwitserloot <reinier@zwitserloot.com>2013-07-16 00:51:31 +0200
commit7af9add9996f2efab6cccc50c5503b3457534930 (patch)
treebd224bd341da31e1b5aba5e718f43b6fd1227e8d /test/transform/resource/after-delombok
parentec0cc4348cf71d872b796d0733fb64fc576ef5df (diff)
downloadlombok-7af9add9996f2efab6cccc50c5503b3457534930.tar.gz
lombok-7af9add9996f2efab6cccc50c5503b3457534930.tar.bz2
lombok-7af9add9996f2efab6cccc50c5503b3457534930.zip
* Fixed issues with @FieldDefaults and @Value (you can NOT override
@Value's final-by-default and private-by-default with it; now appropriate warnings are emitted) * Builder now errors out on presence of most lombok annotations on an explicit builder class. * Builder now takes @FieldDefaults/@Value into account. * Builder on type now generates the constructor as package private instead of private to avoid synthetic accessor constructors. * added a bunch of test cases. * added a test case feature: If the expected file is omitted entirely but there are expected messages, the differences in the output itself are ignored. * streamlined checking for boolean-ness (removed some duplicate code) * added 'fluent' and 'chain' to @Builder.
Diffstat (limited to 'test/transform/resource/after-delombok')
-rw-r--r--test/transform/resource/after-delombok/BuilderChainAndFluent.java31
-rw-r--r--test/transform/resource/after-delombok/BuilderSimple.java2
2 files changed, 32 insertions, 1 deletions
diff --git a/test/transform/resource/after-delombok/BuilderChainAndFluent.java b/test/transform/resource/after-delombok/BuilderChainAndFluent.java
new file mode 100644
index 00000000..d4975bff
--- /dev/null
+++ b/test/transform/resource/after-delombok/BuilderChainAndFluent.java
@@ -0,0 +1,31 @@
+class BuilderChainAndFluent {
+ private final int yes;
+ @java.lang.SuppressWarnings("all")
+ BuilderChainAndFluent(final int yes) {
+ this.yes = yes;
+ }
+ @java.lang.SuppressWarnings("all")
+ public static class BuilderChainAndFluentBuilder {
+ private int yes;
+ @java.lang.SuppressWarnings("all")
+ BuilderChainAndFluentBuilder() {
+ }
+ @java.lang.SuppressWarnings("all")
+ public void setYes(final int yes) {
+ this.yes = yes;
+ }
+ @java.lang.SuppressWarnings("all")
+ public BuilderChainAndFluent build() {
+ return new BuilderChainAndFluent(yes);
+ }
+ @java.lang.Override
+ @java.lang.SuppressWarnings("all")
+ public java.lang.String toString() {
+ return "BuilderChainAndFluent.BuilderChainAndFluentBuilder(yes=" + this.yes + ")";
+ }
+ }
+ @java.lang.SuppressWarnings("all")
+ public static BuilderChainAndFluentBuilder builder() {
+ return new BuilderChainAndFluentBuilder();
+ }
+} \ No newline at end of file
diff --git a/test/transform/resource/after-delombok/BuilderSimple.java b/test/transform/resource/after-delombok/BuilderSimple.java
index 24ac369c..11c0e58c 100644
--- a/test/transform/resource/after-delombok/BuilderSimple.java
+++ b/test/transform/resource/after-delombok/BuilderSimple.java
@@ -5,7 +5,7 @@ class BuilderSimple<T> {
private List<T> also;
private int $butNotMe;
@java.lang.SuppressWarnings("all")
- private BuilderSimple(final int yes, final List<T> also) {
+ BuilderSimple(final int yes, final List<T> also) {
this.yes = yes;
this.also = also;
}