@Entity public class User extends Object implements Serializable
| Constructor and Description |
|---|
User(String email,
String name,
String surname,
GregorianCalendar birthdate,
IdentificationType identificationType,
String numIdentificationType,
String residence,
String location,
String province,
String country,
String phone)
Creates a new instance
User |
User(String email,
String name,
String surname,
GregorianCalendar birthdate,
IdentificationType identificationType,
String numIdentificationType,
String residence,
String location,
String province,
String country,
String phone,
HashMap<String,String> socialNetworks)
Creates a new instance
User |
| Modifier and Type | Method and Description |
|---|---|
GregorianCalendar |
getBirthdate()
Returns the birthdate of the user
|
String |
getCountry()
Returns the country of the user
|
String |
getEmail()
Returns the email of the user
|
IdentificationType |
getIdentificationType()
Returns the identificationType of the user
|
String |
getLocation()
Returns the location of the user
|
String |
getName()
Returns the name of the user
|
String |
getNumIdentificationType()
Returns the user identification number
|
String |
getPhone()
Returns the phone of the user
|
String |
getProvince()
Returns the province of the user
|
String |
getResidence()
Returns the residence of the user
|
HashMap<String,String> |
getSocialNetworks()
Returns the social networks of the user
|
String |
getSurname()
Returns the surname of the user
|
void |
setBirthdate(GregorianCalendar birthdate)
Sets the birthdate of the user
|
void |
setCountry(String country)
Sets the country of the user
|
void |
setEmail(String email)
Sets the email of the user
|
void |
setIdentificationType(IdentificationType identificationType)
Sets the identification type of the user
|
void |
setLocation(String location)
Sets the location of the user
|
void |
setName(String name)
Sets the name of the user
|
void |
setNumIdentificationType(String numIdentificationType)
Sets the user identification number
|
void |
setPhone(String phone)
Sets the phone of the user
|
void |
setProvince(String province)
Sets the province of the user
|
void |
setResidence(String residence)
Sets the residence of the user
|
void |
setSocialNetworks(HashMap<String,String> socialNetworks)
Sets the social networks of the user
|
void |
setSurname(String surname)
Sets the name of the user
|
String |
toString() |
public User(String email, String name, String surname, GregorianCalendar birthdate, IdentificationType identificationType, String numIdentificationType, String residence, String location, String province, String country, String phone, HashMap<String,String> socialNetworks)
Useremail - the email of the user which identifies the user in the system.
Must be a non empty and non null string with a maximum
length of 100 chars.name - the name of the user. Must be a non empty and non null
string with a maximum length of 100 chars.surname - the surname of the user. Must be a non empty and non null
string with a maximum length of 200 chars.birthdate - the birthdate of the user. Must be a non empty and non
null string.identificationType - the enumerated data with all the possibles choices of the system
in identification type of user. Must be a non empty and non
null string.numIdentificationType - the user identification number in the format of the
identificationType. Must be a non empty and non null
string with a maximum length of 50 chars.residence - the residence of the user. Must be a non empty and non
null string with a maximum length of 200 chars.location - the location of the user. Must be a non empty and non null
string with a maximum length of 100 chars.province - the province of the user. Must be a non empty and non null
string with a maximum length of 100 chars.country - the country of the user. Must be a non empty and non null
string with a maximum length of 100 chars.phone - the phone of the user. Must be a non empty and non null
string with a maximum length of 25 chars.socialNetworks - the map of the social networks of the user, with the value of the
social network as a key and the profile in that social network as
a value.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public User(String email, String name, String surname, GregorianCalendar birthdate, IdentificationType identificationType, String numIdentificationType, String residence, String location, String province, String country, String phone)
Useremail - the email of the user which identifies the user in the system.
Must be a non empty and non null string with a maximum
length of 100 chars.name - the name of the user. Must be a non empty and non null
string with a maximum length of 100 chars.surname - the surname of the user. Must be a non empty and non null
string with a maximum length of 200 chars.birthdate - the birthdate of the user. Must be a non empty and non
null string.identificationType - the enumerated data with all the possibles choices of the system
in identification type of user. Must be a non empty and non
null string.numIdentificationType - the user identification number in the format of the
identificationType. Must be a non empty and non null
string with a maximum length of 50 chars.residence - the residence of the user. Must be a non empty and non
null string with a maximum length of 200 chars.location - the location of the user. Must be a non empty and non null
string with a maximum length of 100 chars.province - the province of the user. Must be a non empty and non null
string with a maximum length of 100 chars.country - the country of the user. Must be a non empty and non null
string with a maximum length of 100 chars.phone - the phone of the user. Must be a non empty and non null
string with a maximum length of 25 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getEmail()
public void setEmail(String email)
email - the email of the user which identifies the user in the system.
Must be a non empty and non null string with a maximum
length of 100 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getName()
public void setName(String name)
name - the name of the user. Must be a non empty and non null
string with a maximum length of 100 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getSurname()
public void setSurname(String surname)
surname - the surname of the user. Must be a non empty and non null
string with a maximum length of 200 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public GregorianCalendar getBirthdate()
public void setBirthdate(GregorianCalendar birthdate)
birthdate - the birthdate of the user. Must be a non empty and non
null string.NullPointerException - if a null value is passed as the value for any parameter.public IdentificationType getIdentificationType()
public void setIdentificationType(IdentificationType identificationType)
identificationType - the enumerated data with all the possibles choices of the system
in identification type of user. Must be a non empty and non
null string.NullPointerException - if a null value is passed as the value for any
parameter..public String getNumIdentificationType()
public void setNumIdentificationType(String numIdentificationType)
numIdentificationType - the user identification number in the format of the
identificationType. Must be a non empty and non null
string with a maximum length of 50 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getResidence()
public void setResidence(String residence)
residence - the residence of the user. Must be a non empty and non
null string with a maximum length of 200 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getLocation()
public void setLocation(String location)
location - the location of the user. Must be a non empty and non null
string with a maximum length of 100 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getProvince()
public void setProvince(String province)
province - the province of the user. Must be a non empty and non null
string with a maximum length of 100 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getCountry()
public void setCountry(String country)
country - the country of the user. Must be a non empty and non null
string with a maximum length of 100 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public String getPhone()
public void setPhone(String phone)
phone - the phone of the user. Must be a non empty and non null
string with a maximum length of 25 chars.NullPointerException - if a null value is passed as the value for any parameter.IllegalArgumentException - if value provided for any parameter is not valid according to its
description.public HashMap<String,String> getSocialNetworks()
public void setSocialNetworks(HashMap<String,String> socialNetworks)
socialNetworks - the map of the social networks of the user, with the value of the
social network as a key and the profile in that social network as
a value.Copyright © 2017. All rights reserved.