-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
toBuilder() #72
Comments
I would also like to see something like this on the target class. I usually create two builder methods on my target class, a Example: public class TargetClass {
private double value;
private Targetclass(double value){
this.value = value;
}
public static InnerBuilder builder(){
return new InnerBuilder();
}
public InnerBuilder toBuilder(){
return new InnerBuilder(this);
}
//----------------------
public static final class InnerBuilder {
private double value;
private InnerBuilder() {
}
private InnerBuilder(TargetClass other) {
this.value= other.val;ue;
}
public InnerBuilder value(double value) {
this.value = value;
return this;
}
public InnerBuilder build(){
return new TargetClass(value);
}
}
} |
I just discovered this plugin (it's great, thanks!) and immediately I missed these two methods being generated ffor inner class builders. Would be even better if the builder would not generate the |
Would it be possible to add a toBuilder() method?
The text was updated successfully, but these errors were encountered: