|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object fr.gedeon.telnetservice.StateHolder fr.gedeon.telnetservice.SessionState
public final class SessionState
Holds the state of the session, as well as that of the integrating application relating to the
session.
There is one Session State instance per session, and it is provided by the Session. It is passed
as a parameter to most Session initiated methods and may be referenced for future use. In such
case, it is strongly recommended to register as a SessionListener
and clear the reference
on connection lost event.
The session state provides both a holder to store state info as well as a gateway to useful service
components attached to this session.
Constructor Summary | |
---|---|
SessionState()
|
Method Summary | |
---|---|
void |
disactivateSession()
Set session active flag to false |
Session |
getSession()
|
Object |
getStateEntry(String key)
Retrieve the state entry with the given key. |
boolean |
isSessionActive()
|
void |
putStateEntry(String key,
Object value)
Store the given value with the given key. |
void |
removeStateEntry(String key)
Remove the value stored with this key. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SessionState()
Method Detail |
---|
public Session getSession()
public boolean isSessionActive()
public void disactivateSession()
public Object getStateEntry(String key) throws StateEntryNotFoundException
getStateEntry
in class StateHolder
StateEntryNotFoundException
- if there was no state entries with that key.public void putStateEntry(String key, Object value)
putStateEntry
in class StateHolder
public void removeStateEntry(String key)
removeStateEntry
in class StateHolder
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |