SESSION_ACTIVATED_EVENT, SESSION_CREATED_EVENT, SESSION_DESTROYED_EVENT, SESSION_PASSIVATED_EVENT
Constructor and Description |
---|
DummyProxySession(java.lang.String sessionId) |
Modifier and Type | Method and Description |
---|---|
void |
access()
Update the accessed time information for this session.
|
void |
addSessionListener(SessionListener listener)
Add a session event listener to this component.
|
void |
endAccess()
End access to the session.
|
void |
expire()
Perform the internal processing required to invalidate this session,
without triggering an exception if the session has already expired.
|
java.lang.String |
getAuthType()
Return the authentication type used to authenticate our cached
Principal, if any.
|
long |
getCreationTime()
Return the creation time for this session.
|
long |
getCreationTimeInternal()
Return the creation time for this session, bypassing the session validity
checks.
|
java.lang.String |
getId()
Return the session identifier for this session.
|
java.lang.String |
getIdInternal()
Return the session identifier for this session.
|
long |
getIdleTime()
Return the idle time (in milliseconds) from last client access time.
|
long |
getIdleTimeInternal()
Return the idle time from last client access time without invalidation check
|
long |
getLastAccessedTime()
Return the last time the client sent a request associated with this
session, as the number of milliseconds since midnight, January 1, 1970
GMT.
|
long |
getLastAccessedTimeInternal()
Return the last client access time without invalidation check
|
Manager |
getManager()
Return the Manager within which this Session is valid.
|
int |
getMaxInactiveInterval()
Return the maximum time interval, in seconds, between client requests
before the servlet container will invalidate the session.
|
java.lang.Object |
getNote(java.lang.String name)
Return the object bound with the specified name to the internal notes
for this session, or
null if no such binding exists. |
java.util.Iterator<java.lang.String> |
getNoteNames()
Return an Iterator containing the String names of all notes bindings
that exist for this session.
|
java.security.Principal |
getPrincipal()
Return the authenticated Principal that is associated with this Session.
|
HttpSession |
getSession()
Return the
HttpSession for which this object
is the facade. |
long |
getThisAccessedTime()
Return the last time the client sent a request associated with this
session, as the number of milliseconds since midnight, January 1, 1970
GMT.
|
long |
getThisAccessedTimeInternal()
Return the last client access time without invalidation check
|
boolean |
isAttributeDistributable(java.lang.String name,
java.lang.Object value)
Does the session implementation support the distributing of the given
attribute?
|
boolean |
isValid()
Return the
isValid flag for this session. |
void |
recycle()
Release all object references, and initialize instance variables, in
preparation for reuse of this object.
|
void |
removeNote(java.lang.String name)
Remove any object bound to the specified name in the internal notes
for this session.
|
void |
removeSessionListener(SessionListener listener)
Remove a session event listener from this component.
|
void |
setAuthType(java.lang.String authType)
Set the authentication type used to authenticate our cached
Principal, if any.
|
void |
setCreationTime(long time)
Set the creation time for this session.
|
void |
setId(java.lang.String id)
Set the session identifier for this session and notifies any associated
listeners that a new session has been created.
|
void |
setId(java.lang.String id,
boolean notify)
Set the session identifier for this session and optionally notifies any
associated listeners that a new session has been created.
|
void |
setManager(Manager manager)
Set the Manager within which this Session is valid.
|
void |
setMaxInactiveInterval(int interval)
Set the maximum time interval, in seconds, between client requests
before the servlet container will invalidate the session.
|
void |
setNew(boolean isNew)
Set the
isNew flag for this session. |
void |
setNote(java.lang.String name,
java.lang.Object value)
Bind an object to a specified name in the internal notes associated
with this session, replacing any existing binding for this name.
|
void |
setPrincipal(java.security.Principal principal)
Set the authenticated Principal that is associated with this Session.
|
void |
setValid(boolean isValid)
Set the
isValid flag for this session. |
void |
tellChangedSessionId(java.lang.String newId,
java.lang.String oldId,
boolean notifySessionListeners,
boolean notifyContainerListeners)
Inform the listeners about the change session ID.
|
public void access()
Session
public void addSessionListener(SessionListener listener)
Session
addSessionListener
in interface Session
public void endAccess()
Session
public void expire()
Session
public java.lang.String getAuthType()
Session
getAuthType
in interface Session
public long getCreationTime()
Session
getCreationTime
in interface Session
public long getCreationTimeInternal()
Session
getCreationTimeInternal
in interface Session
public java.lang.String getId()
Session
public java.lang.String getIdInternal()
Session
getIdInternal
in interface Session
public long getLastAccessedTime()
Session
getLastAccessedTime
in interface Session
public long getLastAccessedTimeInternal()
Session
getLastAccessedTimeInternal
in interface Session
Session.getLastAccessedTime()
public long getIdleTime()
Session
getIdleTime
in interface Session
public long getIdleTimeInternal()
Session
getIdleTimeInternal
in interface Session
Session.getIdleTime()
public Manager getManager()
Session
getManager
in interface Session
public int getMaxInactiveInterval()
Session
getMaxInactiveInterval
in interface Session
public java.lang.Object getNote(java.lang.String name)
Session
null
if no such binding exists.public java.util.Iterator<java.lang.String> getNoteNames()
Session
getNoteNames
in interface Session
public java.security.Principal getPrincipal()
Session
Authenticator
with a means to cache a
previously authenticated Principal, and avoid potentially expensive
Realm.authenticate()
calls on every request. If there
is no current associated Principal, return null
.getPrincipal
in interface Session
public HttpSession getSession()
Session
HttpSession
for which this object
is the facade.getSession
in interface Session
public long getThisAccessedTime()
Session
getThisAccessedTime
in interface Session
public long getThisAccessedTimeInternal()
Session
getThisAccessedTimeInternal
in interface Session
Session.getThisAccessedTime()
public boolean isValid()
Session
isValid
flag for this session.public void recycle()
Session
public void removeNote(java.lang.String name)
Session
removeNote
in interface Session
name
- Name of the note to be removedpublic void removeSessionListener(SessionListener listener)
Session
removeSessionListener
in interface Session
public void setAuthType(java.lang.String authType)
Session
setAuthType
in interface Session
authType
- The new cached authentication typepublic void setCreationTime(long time)
Session
setCreationTime
in interface Session
time
- The new creation timepublic void setId(java.lang.String id)
Session
public void setId(java.lang.String id, boolean notify)
Session
public void setManager(Manager manager)
Session
setManager
in interface Session
manager
- The new Managerpublic void setMaxInactiveInterval(int interval)
Session
setMaxInactiveInterval
in interface Session
interval
- The new maximum intervalpublic void setNew(boolean isNew)
Session
isNew
flag for this session.public void setNote(java.lang.String name, java.lang.Object value)
Session
public void setPrincipal(java.security.Principal principal)
Session
Authenticator
with a means to cache a
previously authenticated Principal, and avoid potentially expensive
Realm.authenticate()
calls on every request.setPrincipal
in interface Session
principal
- The new Principal, or null
if nonepublic void setValid(boolean isValid)
Session
isValid
flag for this session.public void tellChangedSessionId(java.lang.String newId, java.lang.String oldId, boolean notifySessionListeners, boolean notifyContainerListeners)
Session
tellChangedSessionId
in interface Session
newId
- new session IDoldId
- old session IDnotifySessionListeners
- Should any associated sessionListeners be
notified that session ID has been changed?notifyContainerListeners
- Should any associated ContainerListeners
be notified that session ID has been changed?public boolean isAttributeDistributable(java.lang.String name, java.lang.Object value)
Session
IllegalArgumentException
thrown if the proposed attribute is
not distributable.
Note that the Manager
implementation may further restrict which
attributes are distributed but a Manager
level restriction should
not trigger an IllegalArgumentException
in
HttpSession.setAttribute(String, Object)
isAttributeDistributable
in interface Session
name
- The attribute namevalue
- The attribute valuetrue
if distribution is supported, otherwise false
Copyright © 2000-2018 Apache Software Foundation. All Rights Reserved.