public final class GrizzlySession
extends org.glassfish.grizzly.http.server.Session
| Constructor and Description |
|---|
GrizzlySession() |
| Modifier and Type | Method and Description |
|---|---|
long |
access()
Updates the "last accessed" timestamp with the current time.
|
long |
getCreationTime()
Returns the time when this session was created, measured
in milliseconds since midnight January 1, 1970 GMT.
|
String |
getIdInternal() |
long |
getTimestamp() |
boolean |
isNew()
Returns
true if the client does not yet know about the
session or if the client chooses not to join the session. |
boolean |
isValid()
Is the current Session valid?
|
void |
setCreationTime(long creationTime)
Set the creation time of this session.
|
void |
setIdInternal(String id)
Sets the session identifier for this session.
|
void |
setTimestamp(long timestamp)
Set the timestamp when this session was accessed the last time.
|
void |
setValid(boolean isValid)
Set this object as validated.
|
public String getIdInternal()
getIdInternal in class org.glassfish.grizzly.http.server.Sessionpublic void setIdInternal(String id)
setIdInternal in class org.glassfish.grizzly.http.server.Sessionid - The internal ID.public boolean isValid()
isValid in class org.glassfish.grizzly.http.server.Sessionpublic void setValid(boolean isValid)
setValid in class org.glassfish.grizzly.http.server.SessionisValid - Set whether this session is valid.public boolean isNew()
true if the client does not yet know about the
session or if the client chooses not to join the session. For
example, if the server used only cookie-based sessions, and
the client had disabled the use of cookies, then a session would
be new on each request.isNew in class org.glassfish.grizzly.http.server.Sessiontrue if the
server has created a session,
but the client has not yet joinedpublic long getCreationTime()
getCreationTime in class org.glassfish.grizzly.http.server.Sessionlong specifying when this session was created,
expressed in milliseconds since 1/1/1970 GMTpublic void setCreationTime(long creationTime)
creationTime - The creation time, in milliseconds.public long getTimestamp()
getTimestamp in class org.glassfish.grizzly.http.server.Sessionpublic void setTimestamp(long timestamp)
setTimestamp in class org.glassfish.grizzly.http.server.Sessiontimestamp - A long representing when the session was last accessed.public long access()
access in class org.glassfish.grizzly.http.server.SessionCopyright © 2018 krotscheck.net. All rights reserved.