public class JabberServerService
extends java.lang.Object
| Constructor and Description |
|---|
JabberServerService(JabberSession session) |
| Modifier and Type | Method and Description |
|---|---|
JIDType |
browse(JID jid,
java.lang.String type,
boolean wait)
browses to the JID that you specify.
|
java.util.List |
discoverItems(JID jid,
java.lang.String node,
boolean wait)
Convenience method to use the service discovery protocol to find service items available for use.
|
java.util.List |
getAgents()
Deprecated.
Replace by new JEP-0030 Service Discovery Protocol
|
java.util.HashMap |
getSearchFields(JID jid)
Convenience method to retrieve the search fields for a particular service.
|
java.lang.String |
getServerTime()
retrieves the server's time in a string.
|
java.lang.String |
getServerTimeInLocal()
retrieves the server's time.
|
long |
getServerUptime()
retrieves the server uptime synchronously.
|
java.lang.String |
getServerVersion()
obtains the server version.
|
java.util.List |
search(JID jid,
java.util.HashMap searchFields,
boolean wait)
convenience method to submit a search to the server.
|
public JabberServerService(JabberSession session)
public java.lang.String getServerTimeInLocal()
throws SendMessageFailedException
SendMessageFailedExceptionpublic java.lang.String getServerTime()
throws SendMessageFailedException
SendMessageFailedExceptionpublic java.lang.String getServerVersion()
throws SendMessageFailedException
SendMessageFailedExceptionpublic long getServerUptime()
throws SendMessageFailedException
SendMessageFailedExceptionpublic java.util.List getAgents()
throws SendMessageFailedException
SendMessageFailedExceptionServiceInfoIQMessage,
ServiceItemsIQMessagepublic JIDType browse(JID jid, java.lang.String type, boolean wait) throws JabberMessageException, SendMessageFailedException, ParseException
jid - the JID of the service/user/resource to browse totype - the JID Type in the format of "category/subtype"wait - whether to wait for reply or just simply send and returnJabberMessageException - if any error occurred while waiting for reply (ie. timeouts)ParseException - if the type passed in is not in the proper formatSendMessageFailedExceptionpublic java.util.HashMap getSearchFields(JID jid) throws SendMessageFailedException, JabberMessageException
jid - the jid to search forSendMessageFailedExceptionJabberMessageExceptionpublic java.util.List search(JID jid, java.util.HashMap searchFields, boolean wait) throws SendMessageFailedException, JabberMessageException
jid - the jid to submit this search to, normally the JUD.searchFields - hashmap of fields that is filled with the search criteriawait - whether to send the message synchronously or asynchronouslySendMessageFailedExceptionJabberMessageExceptionpublic java.util.List discoverItems(JID jid, java.lang.String node, boolean wait) throws SendMessageFailedException, JabberMessageException
jid - the JID to send the discovery request tonode - an optional node name for discovering further items, or null if none is requiredwait - whether to wait for a reply or notSendMessageFailedExceptionJabberMessageExceptionCopyright © 2001-2005 Echomine. All Rights Reserved.