Package org.apache.shiro.web.session.mgt
Class WebSessionKey
- java.lang.Object
-
- org.apache.shiro.session.mgt.DefaultSessionKey
-
- org.apache.shiro.web.session.mgt.WebSessionKey
-
- All Implemented Interfaces:
Serializable,org.apache.shiro.session.mgt.SessionKey,RequestPairSource
public class WebSessionKey extends org.apache.shiro.session.mgt.DefaultSessionKey implements RequestPairSource
ASessionKeyimplementation that also retains theServletRequestandServletResponseassociated with the web request that is performing the session lookup.- Since:
- 1.0
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description WebSessionKey(Serializable sessionId, javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)WebSessionKey(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.servlet.ServletRequestgetServletRequest()Returns the incomingServletRequestassociated with the component.javax.servlet.ServletResponsegetServletResponse()Returns the outgoingServletResponsepaired with the incomingservletRequest.
-
-
-
Constructor Detail
-
WebSessionKey
public WebSessionKey(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
-
WebSessionKey
public WebSessionKey(Serializable sessionId, javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
-
-
Method Detail
-
getServletRequest
public javax.servlet.ServletRequest getServletRequest()
Description copied from interface:RequestPairSourceReturns the incomingServletRequestassociated with the component.- Specified by:
getServletRequestin interfaceRequestPairSource- Returns:
- the incoming
ServletRequestassociated with the component.
-
getServletResponse
public javax.servlet.ServletResponse getServletResponse()
Description copied from interface:RequestPairSourceReturns the outgoingServletResponsepaired with the incomingservletRequest.- Specified by:
getServletResponsein interfaceRequestPairSource- Returns:
- the outgoing
ServletResponsepaired with the incomingservletRequest.
-
-