aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/transform/resource/after-delombok/BuilderComplex.java43
-rw-r--r--test/transform/resource/after-delombok/BuilderSimple.java38
-rw-r--r--test/transform/resource/after-delombok/BuilderWithExistingBuilderClass.java33
3 files changed, 114 insertions, 0 deletions
diff --git a/test/transform/resource/after-delombok/BuilderComplex.java b/test/transform/resource/after-delombok/BuilderComplex.java
new file mode 100644
index 00000000..d6d12ebf
--- /dev/null
+++ b/test/transform/resource/after-delombok/BuilderComplex.java
@@ -0,0 +1,43 @@
+import java.util.List;
+class BuilderComplex {
+ private static <T extends Number> void testVoidWithGenerics(T number, int arg2, String arg3, BuilderComplex selfRef) {
+ }
+ @java.lang.SuppressWarnings("all")
+ public static class VoidBuilder<T extends Number> {
+ private T number;
+ private int arg2;
+ private String arg3;
+ private BuilderComplex selfRef;
+ @java.lang.SuppressWarnings("all")
+ VoidBuilder() {
+ }
+ @java.lang.SuppressWarnings("all")
+ public VoidBuilder<T> number(final T number) {
+ this.number = number;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public VoidBuilder<T> arg2(final int arg2) {
+ this.arg2 = arg2;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public VoidBuilder<T> arg3(final String arg3) {
+ this.arg3 = arg3;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public VoidBuilder<T> selfRef(final BuilderComplex selfRef) {
+ this.selfRef = selfRef;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public void execute() {
+ BuilderComplex.<T>testVoidWithGenerics(number, arg2, arg3, selfRef);
+ }
+ }
+ @java.lang.SuppressWarnings("all")
+ public static <T extends Number> VoidBuilder<T> builder() {
+ return new VoidBuilder<T>();
+ }
+} \ No newline at end of file
diff --git a/test/transform/resource/after-delombok/BuilderSimple.java b/test/transform/resource/after-delombok/BuilderSimple.java
new file mode 100644
index 00000000..113d538e
--- /dev/null
+++ b/test/transform/resource/after-delombok/BuilderSimple.java
@@ -0,0 +1,38 @@
+import java.util.List;
+class BuilderSimple<T> {
+ private final int noshow = 0;
+ private final int yes;
+ private List<T> also;
+ private int $butNotMe;
+ @java.lang.SuppressWarnings("all")
+ private BuilderSimple(final int yes, final List<T> also) {
+ this.yes = yes;
+ this.also = also;
+ }
+ @java.lang.SuppressWarnings("all")
+ public static class BuilderSimpleBuilder<T> {
+ private int yes;
+ private List<T> also;
+ @java.lang.SuppressWarnings("all")
+ BuilderSimpleBuilder() {
+ }
+ @java.lang.SuppressWarnings("all")
+ public BuilderSimpleBuilder<T> yes(final int yes) {
+ this.yes = yes;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public BuilderSimpleBuilder<T> also(final List<T> also) {
+ this.also = also;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public BuilderSimple<T> build() {
+ return new BuilderSimple<T>(yes, also);
+ }
+ }
+ @java.lang.SuppressWarnings("all")
+ public static <T> BuilderSimpleBuilder<T> builder() {
+ return new BuilderSimpleBuilder<T>();
+ }
+}
diff --git a/test/transform/resource/after-delombok/BuilderWithExistingBuilderClass.java b/test/transform/resource/after-delombok/BuilderWithExistingBuilderClass.java
new file mode 100644
index 00000000..a8800009
--- /dev/null
+++ b/test/transform/resource/after-delombok/BuilderWithExistingBuilderClass.java
@@ -0,0 +1,33 @@
+class BuilderWithExistingBuilderClass<T, K extends Number> {
+ public static <Z extends Number> BuilderWithExistingBuilderClass<String, Z> staticMethod(Z arg1, boolean arg2, String arg3) {
+ return null;
+ }
+ public static class BuilderWithExistingBuilderClassBuilder<Z extends Number> {
+ private boolean arg2;
+ private String arg3;
+ private Z arg1;
+ public void arg2(boolean arg) {
+ }
+ @java.lang.SuppressWarnings("all")
+ BuilderWithExistingBuilderClassBuilder() {
+ }
+ @java.lang.SuppressWarnings("all")
+ public BuilderWithExistingBuilderClassBuilder<Z> arg1(final Z arg1) {
+ this.arg1 = arg1;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public BuilderWithExistingBuilderClassBuilder<Z> arg3(final String arg3) {
+ this.arg3 = arg3;
+ return this;
+ }
+ @java.lang.SuppressWarnings("all")
+ public BuilderWithExistingBuilderClass build() {
+ return BuilderWithExistingBuilderClass.<Z>staticMethod(arg1, arg2, arg3);
+ }
+ }
+ @java.lang.SuppressWarnings("all")
+ public static <Z extends Number> BuilderWithExistingBuilderClassBuilder<Z> builder() {
+ return new BuilderWithExistingBuilderClassBuilder<Z>();
+ }
+} \ No newline at end of file