public class Junny {
private String name;
private int age;
private String address;
@Builder
public Junny(String name, int age, String address) {
this.name = name;
this.age = age;
this.address = address;
}
}
public class Junny {
@Setter
@Accessors(chain = true,fluent = true)
public String name;
@Setter
@Accessors(chain = true,fluent = true)
private int age;
@Setter
@Accessors(chain = true,fluent = true)
private String address;
private Junny() {}
public static Junny builder() {
return new Junny();
}
}
Junny junny = Junny.builder()
.name("junny")
.age(10)
.address("seoul");