org.apache.shiro.web.session.mgt
Class DefaultWebSessionContext

java.lang.Object
  extended by org.apache.shiro.util.MapContext
      extended by org.apache.shiro.session.mgt.DefaultSessionContext
          extended by org.apache.shiro.web.session.mgt.DefaultWebSessionContext
All Implemented Interfaces:
Serializable, Map<String,Object>, SessionContext, WebSessionContext, RequestPairSource

public class DefaultWebSessionContext
extends DefaultSessionContext
implements WebSessionContext

Default implementation of the WebSessionContext interface which provides getters and setters that wrap interaction with the underlying backing context map.

Since:
1.0
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface java.util.Map
Map.Entry<K,V>
 
Constructor Summary
DefaultWebSessionContext()
           
DefaultWebSessionContext(Map<String,Object> map)
           
 
Method Summary
 ServletRequest getServletRequest()
          Returns the ServletRequest received by the servlet container triggering the creation of the Session instance.
 ServletResponse getServletResponse()
          The paired ServletResponse corresponding to the associated servletRequest.
 void setServletRequest(ServletRequest request)
          Sets the ServletRequest received by the servlet container triggering the creation of the Session instance.
 void setServletResponse(ServletResponse response)
          Sets the paired ServletResponse corresponding to the associated servletRequest.
 
Methods inherited from class org.apache.shiro.session.mgt.DefaultSessionContext
getHost, getSessionId, setHost, setSessionId
 
Methods inherited from class org.apache.shiro.util.MapContext
clear, containsKey, containsValue, entrySet, get, getTypedValue, isEmpty, keySet, nullSafePut, put, putAll, remove, size, values
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.shiro.session.mgt.SessionContext
getHost, getSessionId, setHost, setSessionId
 
Methods inherited from interface java.util.Map
clear, containsKey, containsValue, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, remove, size, values
 

Constructor Detail

DefaultWebSessionContext

public DefaultWebSessionContext()

DefaultWebSessionContext

public DefaultWebSessionContext(Map<String,Object> map)
Method Detail

setServletRequest

public void setServletRequest(ServletRequest request)
Description copied from interface: WebSessionContext
Sets the ServletRequest received by the servlet container triggering the creation of the Session instance.

Specified by:
setServletRequest in interface WebSessionContext
Parameters:
request - the ServletRequest received by the servlet container triggering the creation of the Session instance.

getServletRequest

public ServletRequest getServletRequest()
Description copied from interface: WebSessionContext
Returns the ServletRequest received by the servlet container triggering the creation of the Session instance.

Specified by:
getServletRequest in interface WebSessionContext
Specified by:
getServletRequest in interface RequestPairSource
Returns:
the ServletRequest received by the servlet container triggering the creation of the Session instance.

setServletResponse

public void setServletResponse(ServletResponse response)
Description copied from interface: WebSessionContext
Sets the paired ServletResponse corresponding to the associated servletRequest.

Specified by:
setServletResponse in interface WebSessionContext
Parameters:
response - The paired ServletResponse corresponding to the associated servletRequest.

getServletResponse

public ServletResponse getServletResponse()
Description copied from interface: WebSessionContext
The paired ServletResponse corresponding to the associated servletRequest.

Specified by:
getServletResponse in interface WebSessionContext
Specified by:
getServletResponse in interface RequestPairSource
Returns:
the paired ServletResponse corresponding to the associated servletRequest.


Copyright © 2004-2014 The Apache Software Foundation. All Rights Reserved.