Builder design pattern for Person class.
This commit is contained in:
parent
8a7b1b19c1
commit
8d36387ef0
@ -2,12 +2,14 @@ package pl.amu.edu.demo.data;
|
|||||||
|
|
||||||
import lombok.AccessLevel;
|
import lombok.AccessLevel;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
import lombok.experimental.FieldDefaults;
|
import lombok.experimental.FieldDefaults;
|
||||||
|
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
|
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor(access = AccessLevel.PRIVATE)
|
||||||
@FieldDefaults(level = AccessLevel.PUBLIC, makeFinal = true)
|
@FieldDefaults(level = AccessLevel.PUBLIC, makeFinal = true)
|
||||||
|
@Builder
|
||||||
public class Person {
|
public class Person {
|
||||||
String displayName;
|
String displayName;
|
||||||
String firstName;
|
String firstName;
|
||||||
|
Loading…
Reference in New Issue
Block a user