|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectSnacCommand
ConnCommand
SetIdleCmd
A SNAC command used to set how long the user has been idle. This command
should only be sent once when the user becomes idle; the server will handle
increasing the amount of idle time as time progresses. When the user becomes
unidle, the command should be sent with an idle time value of zero
(SetIdleCmd.IDLETIME_NOT_IDLE
).
0x01
, command 0x11
Field Summary | |
static long |
IDLETIME_NOT_IDLE
An idle time value (0l) indicating that the user is not idle. |
Fields inherited from class SnacCommand |
SNACFLAG_DEFAULT |
Constructor Summary | |
|
SetIdleCmd(long seconds)
Creates a new outgoing set idle time command with the given number of seconds idle. |
protected |
SetIdleCmd(SnacPacket packet)
Generates a new set idle time command from the given incoming SNAC packet. |
Method Summary | |
long |
getSecondsIdle()
Returns the number of seconds the user has been idle, as sent in this command. |
java.lang.String |
toString()
|
void |
writeData(java.io.OutputStream out)
Writes this command's SNAC data block to the given stream. |
Methods inherited from class SnacCommand |
getCommand, getFamily, getFlag1, getFlag2 |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final long IDLETIME_NOT_IDLE
Constructor Detail |
protected SetIdleCmd(SnacPacket packet)
packet
- the incoming set idle time packetpublic SetIdleCmd(long seconds)
seconds
is 0
, the idle time
is reset to zero and the user is marked "active" until another set idle
time command is sent with a nonzero value.
seconds
- the number of seconds the user has been idleMethod Detail |
public final long getSecondsIdle()
public void writeData(java.io.OutputStream out) throws java.io.IOException
SnacCommand
writeData
in class SnacCommand
out
- the stream to which to write the SNAC data
java.io.IOException
- if an I/O error occurspublic java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |