aboutsummaryrefslogtreecommitdiffstats
path: root/src/net/java/sip/communicator/service/contactsource
diff options
context:
space:
mode:
authorLyubomir Marinov <lyubomir.marinov@jitsi.org>2011-02-16 10:12:58 +0000
committerLyubomir Marinov <lyubomir.marinov@jitsi.org>2011-02-16 10:12:58 +0000
commit2ec8f1b300b23af5f48255b88f421a257d75fa61 (patch)
tree94f86d4b52ca411bfffe1b62cd122188b56492c3 /src/net/java/sip/communicator/service/contactsource
parent02e2cf6808ec86313aeb00e515ffbbe4a36e057c (diff)
downloadjitsi-2ec8f1b300b23af5f48255b88f421a257d75fa61.zip
jitsi-2ec8f1b300b23af5f48255b88f421a257d75fa61.tar.gz
jitsi-2ec8f1b300b23af5f48255b88f421a257d75fa61.tar.bz2
Reports contact specifiers such as Home, Work, Mobile for the SourceContact ContactDetails returned by the Mac OS X Address Book ContactSourceService.
Diffstat (limited to 'src/net/java/sip/communicator/service/contactsource')
-rw-r--r--src/net/java/sip/communicator/service/contactsource/ContactDetail.java12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/net/java/sip/communicator/service/contactsource/ContactDetail.java b/src/net/java/sip/communicator/service/contactsource/ContactDetail.java
index 1dcaa38..92b47a7 100644
--- a/src/net/java/sip/communicator/service/contactsource/ContactDetail.java
+++ b/src/net/java/sip/communicator/service/contactsource/ContactDetail.java
@@ -117,7 +117,11 @@ public class ContactDetail
* @param labels the set of labels with which the new <tt>ContactDetail</tt>
* instance is to be labeled. The labels may be arbitrary and may include
* any of the standard/well-known labels defined by the <tt>LABEL_XXX</tt>
- * constants of the <tt>ContactDetail</tt> class.
+ * constants of the <tt>ContactDetail</tt> class. For the sake of
+ * convenience, <tt>null</tt> and duplicate values in the specified
+ * <tt>String[]</tt> <tt>labels</tt> will be ignored i.e. will not appear in
+ * the set of labels reported by the new <tt>ContactDetail</tt> instance
+ * later on.
*/
public ContactDetail(String contactAddress, String[] labels)
{
@@ -126,14 +130,10 @@ public class ContactDetail
// labels
if (labels != null)
{
- System.err.println(this.contactAddress);
for (String label : labels)
{
- if (!this.labels.contains(label))
- {
+ if ((label != null) && !this.labels.contains(label))
this.labels.add(label);
- System.err.println("\t" + label);
- }
}
}
}