-
Notifications
You must be signed in to change notification settings - Fork 0
/
User.java
64 lines (53 loc) · 1.53 KB
/
User.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
import java.util.UUID;
public class User {
private UUID id;
private String userName;
private String password;
private String firstName;
private String lastName;
private String email;
private int privacyLevel;
public User(String userName, String password, String firstName, String lastName, String email, int privacyLevel) {
this.id = UUID.randomUUID();
this.userName = userName;
this.password = password;
this.firstName = firstName;
this.lastName = lastName;
this.email = email;
this.privacyLevel = privacyLevel;
}
public User(UUID id, String userName, String password, String firstName, String lastName, String email, int privacyLevel) {
this.id = id;
this.userName = userName;
this.password = password;
this.firstName = firstName;
this.lastName = lastName;
this.email = email;
this.privacyLevel = privacyLevel;
}
public UUID getId() {
return id;
}
public String getUserName() {
return userName;
}
public String getPassword() {
return password;
}
public String getFirstName() {
return firstName;
}
public String getLastName() {
return lastName;
}
public String getEmail() {
return email;
}
public String getPrivacyLevel() {
return Integer.toString(privacyLevel);
}
@Override
public String toString() {
return "User [userId=" + id + ", username=" + userName + "]";
}
}