aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/juick/User.java
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2016-04-08 16:22:07 +0300
committerGravatar Vitaly Takmazov2016-04-08 16:23:15 +0300
commit80cd101bf9291cd9e8b1a883e3148ff95c445cc1 (patch)
treeaa44e63c2b2a7a6e09d9b88a858d9a95fd7f693a /src/main/java/com/juick/User.java
parentd23e7fff4da9bbfd7ee85ff34c78de631d55c4a5 (diff)
encapsulate some properties
Diffstat (limited to 'src/main/java/com/juick/User.java')
-rw-r--r--src/main/java/com/juick/User.java24
1 files changed, 20 insertions, 4 deletions
diff --git a/src/main/java/com/juick/User.java b/src/main/java/com/juick/User.java
index 40a3df963..13df20587 100644
--- a/src/main/java/com/juick/User.java
+++ b/src/main/java/com/juick/User.java
@@ -28,9 +28,9 @@ public class User {
public Object Avatar = null;
private String FullName = null;
private String JID = null;
- public int MessagesCount = 0;
+ private int unreadCount;
private String AuthHash = null;
- public boolean Banned = false;
+ private boolean banned = false;
public User() {
}
@@ -41,9 +41,9 @@ public class User {
Avatar = u.Avatar;
setFullName(u.getFullName());
setJID(u.getJID());
- MessagesCount = u.MessagesCount;
+ setUnreadCount(u.getUnreadCount());
setAuthHash(u.getAuthHash());
- Banned = u.Banned;
+ setBanned(u.isBanned());
}
@Override
@@ -90,4 +90,20 @@ public class User {
public void setAuthHash(String authHash) {
AuthHash = authHash;
}
+
+ public int getUnreadCount() {
+ return unreadCount;
+ }
+
+ public void setUnreadCount(int unreadCount) {
+ this.unreadCount = unreadCount;
+ }
+
+ public boolean isBanned() {
+ return banned;
+ }
+
+ public void setBanned(boolean banned) {
+ this.banned = banned;
+ }
}