aboutsummaryrefslogtreecommitdiff
path: root/test/transform/resource/after-ecj
diff options
context:
space:
mode:
authorReinier Zwitserloot <r.zwitserloot@projectlombok.org>2020-02-15 07:14:03 +0100
committerReinier Zwitserloot <r.zwitserloot@projectlombok.org>2020-02-15 07:23:16 +0100
commit7993aa20cd20cdc030f90ee9f33c1b74c023d7ca (patch)
tree8df26ee1635a1fe6e2c0e707bba51f314af439f2 /test/transform/resource/after-ecj
parenta991bebe41bd5037323f682301a5fe77ea89b7b9 (diff)
downloadlombok-7993aa20cd20cdc030f90ee9f33c1b74c023d7ca.tar.gz
lombok-7993aa20cd20cdc030f90ee9f33c1b74c023d7ca.tar.bz2
lombok-7993aa20cd20cdc030f90ee9f33c1b74c023d7ca.zip
[issue #2368] [withBy] support for ecj
Diffstat (limited to 'test/transform/resource/after-ecj')
-rw-r--r--test/transform/resource/after-ecj/WithByNullAnnos.java11
-rw-r--r--test/transform/resource/after-ecj/WithByTypes.java53
2 files changed, 64 insertions, 0 deletions
diff --git a/test/transform/resource/after-ecj/WithByNullAnnos.java b/test/transform/resource/after-ecj/WithByNullAnnos.java
new file mode 100644
index 00000000..ff140192
--- /dev/null
+++ b/test/transform/resource/after-ecj/WithByNullAnnos.java
@@ -0,0 +1,11 @@
+import java.util.List;
+public @lombok.RequiredArgsConstructor class WithByNullAnnos {
+ final @lombok.experimental.WithBy List<String> test;
+ public @org.checkerframework.checker.nullness.qual.NonNull @java.lang.SuppressWarnings("all") WithByNullAnnos withTestBy(final java.util.function. @org.checkerframework.checker.nullness.qual.NonNull Function<? super List<String>, ? extends List<String>> transformer) {
+ return new WithByNullAnnos(transformer.apply(this.test));
+ }
+ public @java.lang.SuppressWarnings("all") WithByNullAnnos(final List<String> test) {
+ super();
+ this.test = test;
+ }
+} \ No newline at end of file
diff --git a/test/transform/resource/after-ecj/WithByTypes.java b/test/transform/resource/after-ecj/WithByTypes.java
new file mode 100644
index 00000000..b997ffba
--- /dev/null
+++ b/test/transform/resource/after-ecj/WithByTypes.java
@@ -0,0 +1,53 @@
+public @lombok.RequiredArgsConstructor @lombok.experimental.FieldDefaults(level = lombok.AccessLevel.PRIVATE,makeFinal = true) @lombok.experimental.WithBy class WithByTypes<T> {
+ private final int a;
+ private final long b;
+ private final short c;
+ private final char d;
+ private final byte e;
+ private final double f;
+ private final float g;
+ private final boolean h;
+ private final T i;
+ public static void example() {
+ new WithByTypes<String>(0, 0, (short) 0, ' ', (byte) 0, 0.0, 0.0F, true, "").withHBy((<no type> x) -> (! x)).withFBy((<no type> x) -> (x + 0.5));
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes(final int a, final long b, final short c, final char d, final byte e, final double f, final float g, final boolean h, final T i) {
+ super();
+ this.a = a;
+ this.b = b;
+ this.c = c;
+ this.d = d;
+ this.e = e;
+ this.f = f;
+ this.g = g;
+ this.h = h;
+ this.i = i;
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withABy(final java.util.function.IntUnaryOperator transformer) {
+ return new WithByTypes<T>(transformer.applyAsInt(this.a), this.b, this.c, this.d, this.e, this.f, this.g, this.h, this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withBBy(final java.util.function.LongUnaryOperator transformer) {
+ return new WithByTypes<T>(this.a, transformer.applyAsLong(this.b), this.c, this.d, this.e, this.f, this.g, this.h, this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withCBy(final java.util.function.IntUnaryOperator transformer) {
+ return new WithByTypes<T>(this.a, this.b, (short) transformer.applyAsInt(this.c), this.d, this.e, this.f, this.g, this.h, this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withDBy(final java.util.function.IntUnaryOperator transformer) {
+ return new WithByTypes<T>(this.a, this.b, this.c, (char) transformer.applyAsInt(this.d), this.e, this.f, this.g, this.h, this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withEBy(final java.util.function.IntUnaryOperator transformer) {
+ return new WithByTypes<T>(this.a, this.b, this.c, this.d, (byte) transformer.applyAsInt(this.e), this.f, this.g, this.h, this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withFBy(final java.util.function.DoubleUnaryOperator transformer) {
+ return new WithByTypes<T>(this.a, this.b, this.c, this.d, this.e, transformer.applyAsDouble(this.f), this.g, this.h, this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withGBy(final java.util.function.DoubleUnaryOperator transformer) {
+ return new WithByTypes<T>(this.a, this.b, this.c, this.d, this.e, this.f, (float) transformer.applyAsDouble(this.g), this.h, this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withHBy(final java.util.function.UnaryOperator<java.lang.Boolean> transformer) {
+ return new WithByTypes<T>(this.a, this.b, this.c, this.d, this.e, this.f, this.g, transformer.apply(this.h), this.i);
+ }
+ public @java.lang.SuppressWarnings("all") WithByTypes<T> withIBy(final java.util.function.Function<? super T, ? extends T> transformer) {
+ return new WithByTypes<T>(this.a, this.b, this.c, this.d, this.e, this.f, this.g, this.h, transformer.apply(this.i));
+ }
+} \ No newline at end of file