forked from projectlombok/lombok
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
projectlombok#2596 Builder's setter prefix configurable from lombok.c…
…onfig
- Loading branch information
Showing
9 changed files
with
107 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
test/transform/resource/after-delombok/BuilderSimpleWithSetterPrefixConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import java.util.List; | ||
class BuilderSimpleWithSetterPrefix<T> { | ||
private int unprefixed; | ||
@java.lang.SuppressWarnings("all") | ||
BuilderSimpleWithSetterPrefix(final int unprefixed) { | ||
this.unprefixed = unprefixed; | ||
} | ||
@java.lang.SuppressWarnings("all") | ||
protected static class BuilderSimpleWithSetterPrefixBuilder<T> { | ||
@java.lang.SuppressWarnings("all") | ||
private int unprefixed; | ||
@java.lang.SuppressWarnings("all") | ||
BuilderSimpleWithSetterPrefixBuilder() { | ||
} | ||
/** | ||
* @return {@code this}. | ||
*/ | ||
@java.lang.SuppressWarnings("all") | ||
public BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder<T> withUnprefixed(final int unprefixed) { | ||
this.unprefixed = unprefixed; | ||
return this; | ||
} | ||
@java.lang.SuppressWarnings("all") | ||
public BuilderSimpleWithSetterPrefix<T> build() { | ||
return new BuilderSimpleWithSetterPrefix<T>(this.unprefixed); | ||
} | ||
@java.lang.Override | ||
@java.lang.SuppressWarnings("all") | ||
public java.lang.String toString() { | ||
return "BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder(unprefixed=" + this.unprefixed + ")"; | ||
} | ||
} | ||
@java.lang.SuppressWarnings("all") | ||
protected static <T> BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder<T> builder() { | ||
return new BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder<T>(); | ||
} | ||
} |
30 changes: 30 additions & 0 deletions
30
test/transform/resource/after-ecj/BuilderSimpleWithSetterPrefixConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import java.util.List; | ||
@lombok.Builder(access = lombok.AccessLevel.PROTECTED) class BuilderSimpleWithSetterPrefix<T> { | ||
protected static @java.lang.SuppressWarnings("all") class BuilderSimpleWithSetterPrefixBuilder<T> { | ||
private @java.lang.SuppressWarnings("all") int unprefixed; | ||
@java.lang.SuppressWarnings("all") BuilderSimpleWithSetterPrefixBuilder() { | ||
super(); | ||
} | ||
/** | ||
* @return {@code this}. | ||
*/ | ||
public @java.lang.SuppressWarnings("all") BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder<T> withUnprefixed(final int unprefixed) { | ||
this.unprefixed = unprefixed; | ||
return this; | ||
} | ||
public @java.lang.SuppressWarnings("all") BuilderSimpleWithSetterPrefix<T> build() { | ||
return new BuilderSimpleWithSetterPrefix<T>(this.unprefixed); | ||
} | ||
public @java.lang.Override @java.lang.SuppressWarnings("all") java.lang.String toString() { | ||
return (("BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder(unprefixed=" + this.unprefixed) + ")"); | ||
} | ||
} | ||
private int unprefixed; | ||
@java.lang.SuppressWarnings("all") BuilderSimpleWithSetterPrefix(final int unprefixed) { | ||
super(); | ||
this.unprefixed = unprefixed; | ||
} | ||
protected static @java.lang.SuppressWarnings("all") <T>BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder<T> builder() { | ||
return new BuilderSimpleWithSetterPrefix.BuilderSimpleWithSetterPrefixBuilder<T>(); | ||
} | ||
} |
8 changes: 8 additions & 0 deletions
8
test/transform/resource/before/BuilderSimpleWithSetterPrefixConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
//CONF: lombok.builder.setterPrefix = with | ||
|
||
import java.util.List; | ||
|
||
@lombok.Builder(access = lombok.AccessLevel.PROTECTED) | ||
class BuilderSimpleWithSetterPrefix<T> { | ||
private int unprefixed; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters