68 lines
1.2 KiB
Java
68 lines
1.2 KiB
Java
package cvbuilder.model;
|
|
|
|
public class User {
|
|
|
|
private String name;
|
|
private String title;
|
|
private String email;
|
|
private String phone;
|
|
private String address;
|
|
|
|
|
|
public String getUserAttribute(String panelName) {
|
|
return switch (panelName.toLowerCase()) {
|
|
case "title" -> getTitle();
|
|
case "name" -> getName();
|
|
case "email" -> getEmail();
|
|
case "phone" -> getPhone();
|
|
case "address" -> getAddress();
|
|
default -> "method error";
|
|
};
|
|
}
|
|
|
|
|
|
|
|
//basic getters and setters
|
|
public String getAddress() {
|
|
return address;
|
|
}
|
|
|
|
public void setAddress(String address) {
|
|
this.address = address;
|
|
}
|
|
|
|
public String getPhone() {
|
|
return phone;
|
|
}
|
|
|
|
public void setPhone(String phone) {
|
|
this.phone = phone;
|
|
}
|
|
|
|
public String getEmail() {
|
|
return email;
|
|
}
|
|
|
|
public void setEmail(String email) {
|
|
this.email = email;
|
|
}
|
|
|
|
public String getTitle() {
|
|
return title;
|
|
}
|
|
|
|
public void setTitle(String title) {
|
|
this.title = title;
|
|
}
|
|
|
|
public String getName() {
|
|
return name;
|
|
}
|
|
|
|
public void setName(String name) {
|
|
this.name = name;
|
|
}
|
|
|
|
|
|
}
|