diff options
author | Yana Stamcheva <yana@jitsi.org> | 2010-03-10 21:24:35 +0000 |
---|---|---|
committer | Yana Stamcheva <yana@jitsi.org> | 2010-03-10 21:24:35 +0000 |
commit | 2fb1812a15f8a80410e01f7c1ace670740c786bb (patch) | |
tree | fdb4bc69e8aa30e6ffe76ee4e12c9f9f49f5c5b4 /src/net/java/sip/communicator/service/contactsource/ContactQuery.java | |
parent | 926a6a59a73159c373273c5c9daa4b933514c51b (diff) | |
download | jitsi-2fb1812a15f8a80410e01f7c1ace670740c786bb.zip jitsi-2fb1812a15f8a80410e01f7c1ace670740c786bb.tar.gz jitsi-2fb1812a15f8a80410e01f7c1ace670740c786bb.tar.bz2 |
Some name adjustments in the new contact source service.
Diffstat (limited to 'src/net/java/sip/communicator/service/contactsource/ContactQuery.java')
-rw-r--r-- | src/net/java/sip/communicator/service/contactsource/ContactQuery.java | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/src/net/java/sip/communicator/service/contactsource/ContactQuery.java b/src/net/java/sip/communicator/service/contactsource/ContactQuery.java new file mode 100644 index 0000000..fd33745 --- /dev/null +++ b/src/net/java/sip/communicator/service/contactsource/ContactQuery.java @@ -0,0 +1,43 @@ +/* + * SIP Communicator, the OpenSource Java VoIP and Instant Messaging client. + * + * Distributable under LGPL license. + * See terms of license at gnu.org. + */ +package net.java.sip.communicator.service.contactsource; + +/** + * The <tt>ContactQuery</tt> corresponds to a particular query made through the + * <tt>ContactSourceService</tt>. Each query once started could be + * canceled. One could also register a listener in order to be notified for + * changes in query status and query contact results. + * + * @author Yana Stamcheva + */ +public interface ContactQuery +{ + /** + * Cancels this query. + */ + public void cancel(); + + /** + * Adds the given <tt>ContactQueryListener</tt> to the list of registered + * listeners. The <tt>ContactQueryListener</tt> would be notified each + * time a new <tt>ContactQuery</tt> result has been received or if the + * query has been completed or has been canceled by user or for any other + * reason. + * @param l the <tt>ContactQueryListener</tt> to add + */ + public void addContactQueryListener(ContactQueryListener l); + + /** + * Removes the given <tt>ContactQueryListener</tt> to the list of + * registered listeners. The <tt>ContactQueryListener</tt> would be + * notified each time a new <tt>ContactQuery</tt> result has been received + * or if the query has been completed or has been canceled by user or for + * any other reason. + * @param l the <tt>ContactQueryListener</tt> to remove + */ + public void removeContactQueryListener(ContactQueryListener l); +} |