|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.deegree.security.session.Session
public class Session
Constructor Summary | |
---|---|
Session()
creates a session that never expires for an anonymous user |
|
Session(int duration)
creates a session with a specific lifetime for an anonymous user. the expiration date will be updated each time a user accesses his session |
|
Session(SessionID sessionID)
creates a session with a specific SessionID for an anonymous user. the expiration date will be updated each time a uses accesses his session |
|
Session(java.lang.String user)
creates a session that never expires |
|
Session(java.lang.String user,
int duration)
creates a session with a specific lifetime. the expiration date will be updated each time a uses accesses his session |
|
Session(java.lang.String user,
SessionID sessionID)
creates a session with a specific SessionID. the expiration date will be updated each time a uses accesses his session |
Method Summary | |
---|---|
void |
addAttribute(java.lang.Object key,
java.lang.Object value)
adds an attribute to the session. calling this method will reset the expiration date of the encapsulated sessionID this method throws an exception if the sessinID has been killed or is alive anymore |
void |
close()
kills a Session by marking the encapsulated SessionID as invalid. |
java.lang.Object |
getAttribute(java.lang.Object key)
returns the values of the attribute identified by the passed key. calling this method will reset the expiration date of the encapsulated sessionID this method throws an exception if the sessinID has been killed or is alive anymore |
SessionID |
getSessionID()
returns the sessionID encapsulated in this session. |
java.lang.String |
getUser()
returns the name user the user who owns the session. returns null if its a session for an anonymous user |
boolean |
isAlive()
returns true if the session is still alive or false if the expiration date of the sessionID has been reached |
java.lang.Object |
removeAttribute(java.lang.Object key)
removes the attribute identified by the passed key from the session. calling this method will reset the expiration date of the encapsulated sessionID this method throws an exception if the sessinID has been killed or is alive anymore |
void |
reset()
resets the expiration date of the session |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Session()
public Session(java.lang.String user)
user
- user the session is assigned topublic Session(int duration)
duration
- public Session(java.lang.String user, int duration)
duration
- user
- public Session(SessionID sessionID)
sessionID
- public Session(java.lang.String user, SessionID sessionID)
sessionID
- user
- Method Detail |
---|
public java.lang.String getUser()
null
if its a
session for an anonymous userpublic void addAttribute(java.lang.Object key, java.lang.Object value) throws SessionStatusException
key
- value
-
SessionStatusException
public java.lang.Object getAttribute(java.lang.Object key) throws SessionStatusException
key
-
SessionStatusException
public java.lang.Object removeAttribute(java.lang.Object key) throws SessionStatusException
key
-
SessionStatusException
public boolean isAlive()
true
if the session is still alive or false
if the
expiration date of the sessionID has been reachedpublic SessionID getSessionID()
public void close()
public void reset() throws SessionStatusException
SessionStatusException
|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org