aboutsummaryrefslogtreecommitdiff
path: root/test/transform/resource/before
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@zwitserloot.com>2015-07-17 10:48:10 +0200
committerReinier Zwitserloot <reinier@zwitserloot.com>2015-07-17 10:48:10 +0200
commite2289ef2007981ff285bc7221e89b99211598e27 (patch)
treeddb623e347e26055d3a819e39f57eb1bd162c554 /test/transform/resource/before
parenta17d1fc13db231bd84996d7f8fd68d5514f5aab8 (diff)
downloadlombok-e2289ef2007981ff285bc7221e89b99211598e27.tar.gz
lombok-e2289ef2007981ff285bc7221e89b99211598e27.tar.bz2
lombok-e2289ef2007981ff285bc7221e89b99211598e27.zip
added testcase for ecj version of @Builder(toBuilder=true)
Diffstat (limited to 'test/transform/resource/before')
-rw-r--r--test/transform/resource/before/BuilderWithToBuilder.java13
1 files changed, 4 insertions, 9 deletions
diff --git a/test/transform/resource/before/BuilderWithToBuilder.java b/test/transform/resource/before/BuilderWithToBuilder.java
index 98b7cebc..63e16ae8 100644
--- a/test/transform/resource/before/BuilderWithToBuilder.java
+++ b/test/transform/resource/before/BuilderWithToBuilder.java
@@ -1,36 +1,31 @@
import java.util.List;
import lombok.Builder;
-
@Builder(toBuilder = true) @lombok.experimental.Accessors(prefix = "m")
class BuilderWithToBuilder<T> {
private String mOne, mTwo;
@Builder.ObtainVia(method = "rrr", isStatic = true) private T foo;
@lombok.Singular private List<T> bars;
-
public static <K> K rrr(BuilderWithToBuilder<K> x) {
return x.foo;
}
}
-
@lombok.experimental.Accessors(prefix = "m")
class ConstructorWithToBuilder<T> {
private String mOne, mTwo;
private T foo;
@lombok.Singular private List<T> bars;
-
@Builder(toBuilder = true)
public ConstructorWithToBuilder(String mOne, @Builder.ObtainVia(field = "foo") T bar) {
}
}
-
@lombok.experimental.Accessors(prefix = "m")
-class StaticWithToBuilder<T> {
+class StaticWithToBuilder<T, K> {
private String mOne, mTwo;
private T foo;
+ private K bar;
@lombok.Singular private List<T> bars;
-
@Builder(toBuilder = true)
- public static <Z> StaticWithToBuilder<Z> test(String mOne, @Builder.ObtainVia(field = "foo") Z bar) {
- return new StaticWithToBuilder<Z>();
+ public static <Z> StaticWithToBuilder<Z, String> test(String mOne, @Builder.ObtainVia(field = "foo") Z bar) {
+ return new StaticWithToBuilder<Z, String>();
}
}