|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.echomine.jabber.JabberServerService
public class JabberServerService
the server service contains the methods that you will use 90% of the time. For the rest, you will need to manually create the individual methods (should be easy) and work with the message object directly.
Constructor Summary | |
---|---|
JabberServerService(JabberSession session)
|
Method Summary | |
---|---|
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. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JabberServerService(JabberSession session)
Method Detail |
---|
public java.lang.String getServerTimeInLocal() throws SendMessageFailedException
SendMessageFailedException
public java.lang.String getServerTime() throws SendMessageFailedException
SendMessageFailedException
public java.lang.String getServerVersion() throws SendMessageFailedException
SendMessageFailedException
public long getServerUptime() throws SendMessageFailedException
SendMessageFailedException
public java.util.List getAgents() throws SendMessageFailedException
SendMessageFailedException
ServiceInfoIQMessage
,
ServiceItemsIQMessage
public 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 return
JabberMessageException
- if any error occurred while waiting for reply (ie. timeouts)
ParseException
- if the type passed in is not in the proper format
SendMessageFailedException
public java.util.HashMap getSearchFields(JID jid) throws SendMessageFailedException, JabberMessageException
jid
- the jid to search for
SendMessageFailedException
JabberMessageException
public 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 asynchronously
SendMessageFailedException
JabberMessageException
public 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 not
SendMessageFailedException
JabberMessageException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |