Right now, if you want to set setters for attributes in a class
you can
a) write @Setter above the class or
b) write @Setter above every attribute that you think should have one, individually.
I suggest you add @NoSetter to make it possible to simplify the coding if you only want one attribute not to have a setter.
//current:
@Getter
...
public class PrivateCustomer extends AbstractCustomer {
private long id;
@Setter
private String name;
@Setter
private String email;
}
//new:
@Getter
@Setter
...
public class PrivateCustomer extends AbstractCustomer {
@NoSetter
private long id;
private String name;
private String email;
}
Use @Setter(AccessLevel=NONE) on the field.
Most helpful comment
Use
@Setter(AccessLevel=NONE)on the field.