Files
myhealth/1.sources/MyHealth/src/TO/PatientTO.java
2019-12-21 18:47:31 +01:00

111 lines
2.2 KiB
Java

package TO;
import java.io.Serializable;
import javax.xml.bind.annotation.XmlRootElement;
/**
*
* @author Marcos García Núñez (mgarcianun@uoc.edu)
*
*/
@XmlRootElement(name = "Patient")
public class PatientTO implements Serializable {
private static final long serialVersionUID = 1L;
private Integer id;
private String personalIdentificationCode;
private String nif;
private String name;
private String surname;
private String password;
private String email;
private FamilyDoctorTO familyDoctor;
/**
* Class constructor methods
*/
public PatientTO() {
super();
}
public PatientTO(Integer id, String pic, String nif, String name, String surname, String password, String email, FamilyDoctorTO familyDoc) {
this.id = id;
this.personalIdentificationCode = pic;
this.nif = nif;
this.name = name;
this.surname = surname;
this.password = password;
this.email =email;
this.familyDoctor = familyDoc;
}
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
public String getSurname() {
return surname;
}
public void setSurname(String surname) {
this.surname = surname;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getNif() {
return nif;
}
public void setNif(String nif) {
this.nif = nif;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getDisplayName() {
return String.format("[%s] %s %s", this.personalIdentificationCode, this.name, this.surname);
}
public FamilyDoctorTO getFamilyDoctor() {
return familyDoctor;
}
public void setFamilyDoctor(FamilyDoctorTO familyDoctor) {
this.familyDoctor = familyDoctor;
}
public String getPersonalIdentificationCode() {
return personalIdentificationCode;
}
public void setPersonalIdentificationCode(String personalIdentificationCode) {
this.personalIdentificationCode = personalIdentificationCode;
}
}