aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/entities/Roster.java
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2014-12-22 15:00:51 +0100
committerDaniel Gultsch <daniel@gultsch.de>2014-12-22 15:00:51 +0100
commita94663aaa4d52ba27ada76abe55d2d113304b4e0 (patch)
tree38e73cc693fef7462ecabffd984348a86b768ae3 /src/main/java/eu/siacs/conversations/entities/Roster.java
parent96569700512e9618efa18eeb277665045678e16d (diff)
parentaf7a64491fa5c514866d0f1952c034a7672bb508 (diff)
Merge pull request #796 from SamWhited/xep0191
XEP-0191 Support
Diffstat (limited to 'src/main/java/eu/siacs/conversations/entities/Roster.java')
-rw-r--r--src/main/java/eu/siacs/conversations/entities/Roster.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/main/java/eu/siacs/conversations/entities/Roster.java b/src/main/java/eu/siacs/conversations/entities/Roster.java
index 12a89cec..1a81a419 100644
--- a/src/main/java/eu/siacs/conversations/entities/Roster.java
+++ b/src/main/java/eu/siacs/conversations/entities/Roster.java
@@ -7,7 +7,7 @@ import java.util.concurrent.ConcurrentHashMap;
import eu.siacs.conversations.xmpp.jid.Jid;
public class Roster {
- Account account;
+ final Account account;
final ConcurrentHashMap<String, Contact> contacts = new ConcurrentHashMap<>();
private String version = null;
@@ -19,7 +19,7 @@ public class Roster {
if (jid == null) {
return null;
}
- Contact contact = contacts.get(jid.toBareJid().toString());
+ final Contact contact = contacts.get(jid.toBareJid().toString());
if (contact != null && contact.showInRoster()) {
return contact;
} else {
@@ -32,7 +32,7 @@ public class Roster {
if (contacts.containsKey(bareJid.toString())) {
return contacts.get(bareJid.toString());
} else {
- Contact contact = new Contact(bareJid);
+ final Contact contact = new Contact(bareJid);
contact.setAccount(account);
contacts.put(bareJid.toString(), contact);
return contact;
@@ -46,13 +46,13 @@ public class Roster {
}
public void markAllAsNotInRoster() {
- for (Contact contact : getContacts()) {
+ for (final Contact contact : getContacts()) {
contact.resetOption(Contact.Options.IN_ROSTER);
}
}
public void clearSystemAccounts() {
- for (Contact contact : getContacts()) {
+ for (final Contact contact : getContacts()) {
contact.setPhotoUri(null);
contact.setSystemName(null);
contact.setSystemAccount(null);