public class LastActivity extends IQ
LastActivityManager
to get the last activity of a user.Modifier and Type | Class and Description |
---|---|
static class |
LastActivity.Provider
The IQ Provider for LastActivity.
|
Modifier and Type | Field and Description |
---|---|
long |
lastActivity |
String |
message |
static String |
NAMESPACE |
DEFAULT_LANGUAGE, ID_NOT_AVAILABLE
Constructor and Description |
---|
LastActivity() |
LastActivity(String to) |
Modifier and Type | Method and Description |
---|---|
XmlStringBuilder |
getChildElementXML()
Returns the sub-element XML section of the IQ packet, or null if there
isn't one.
|
long |
getIdleTime()
Returns number of seconds that have passed since the user last logged out.
|
String |
getStatusMessage()
Returns the status message of the last unavailable presence received from the user.
|
void |
setLastActivity(long lastActivity) |
createErrorResponse, createResultIQ, getType, setType, toXML
addCommonAttributes, addExtension, addExtensions, equals, getDefaultLanguage, getError, getExtension, getExtension, getExtensions, getExtensionsXML, getFrom, getPacketID, getTo, getXmlns, hashCode, nextID, removeExtension, setDefaultXmlns, setError, setFrom, setPacketID, setTo, toString
public static final String NAMESPACE
public long lastActivity
public LastActivity()
public LastActivity(String to)
public XmlStringBuilder getChildElementXML()
IQ
Extensions of this class must override this method.
getChildElementXML
in class IQ
public void setLastActivity(long lastActivity)
public long getIdleTime()
public String getStatusMessage()