org.jbrain.qlink
Class QSession
java.lang.Object
|
+--org.jbrain.qlink.QSession
- public class QSession
- extends java.lang.Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OLM_PREFIX
public static final java.lang.String OLM_PREFIX
- See Also:
- Constant Field Values
QSession
public QSession(QLinkServer server,
QConnection link)
getServer
public QLinkServer getServer()
- Returns:
send
public boolean send(Action a)
setState
public void setState(QState state)
send
public void send(Action[] actions)
throws java.io.IOException
java.io.IOException
getState
public QState getState()
- Returns:
terminate
public void terminate()
getStartTime
public java.util.Date getStartTime()
- Returns:
sendOLM
public void sendOLM(java.lang.String[] olm)
- Parameters:
olm
-
getOLM
public java.lang.String[] getOLM(java.lang.String id)
enableOLMs
public void enableOLMs(boolean state)
canReceiveOLMs
public boolean canReceiveOLMs()
- Returns:
suspend
public void suspend()
- Returns:
resume
public void resume()
setAccountInfo
public void setAccountInfo(org.jbrain.qlink.user.AccountInfo account)
getAccountInfo
public org.jbrain.qlink.user.AccountInfo getAccountInfo()
- Returns:
getUserID
public int getUserID()
getAccountID
public int getAccountID()
getHandle
public org.jbrain.qlink.user.QHandle getHandle()
- Returns:
isStaff
public boolean isStaff()
- Returns:
isPrimaryAccount
public boolean isPrimaryAccount()
- Returns:
sendSYSOLM
public void sendSYSOLM(java.lang.String msg)
- Parameters:
msg
-
addEventListener
public void addEventListener(SessionEventListener listener)
getOLM
public java.lang.String[] getOLM()
- Returns:
removeEventListener
public void removeEventListener(SessionEventListener listener)
processEvent
protected void processEvent(SessionEvent event)
processUserNameChangeEvent
protected void processUserNameChangeEvent(UserNameChangeEvent event)
processStateChangeEvent
protected void processStateChangeEvent(StateChangeEvent event)
processTerminationEvent
protected void processTerminationEvent(TerminationEvent event)