接口 javax.servlet.http.HttpSession
的使用

使用 HttpSession 的软件包
javax.servlet.http The javax.servlet.http package contains a number of classes and interfaces that describe and define the contracts between a servlet class running under the HTTP protocol and the runtime environment provided for an instance of such a class by a conforming servlet container. 
javax.servlet.jsp Classes and interfaces for the Core JSP 2.1 API. 
org.apache.jasper.runtime   
org.eclipse.jetty.security.authentication   
org.eclipse.jetty.server   
org.eclipse.jetty.server.session   
 

javax.servlet.httpHttpSession 的使用
 

返回 HttpSessionjavax.servlet.http 中的方法
 HttpSession HttpSessionEvent.getSession()
          Return the session that changed.
 HttpSession HttpSessionBindingEvent.getSession()
          Return the session that changed.
 HttpSession HttpServletRequestWrapper.getSession()
          The default behavior of this method is to return getSession() on the wrapped request object.
 HttpSession HttpServletRequest.getSession()
          Returns the current session associated with this request, or if the request does not have a session, creates one.
 HttpSession HttpServletRequestWrapper.getSession(boolean create)
          The default behavior of this method is to return getSession(boolean create) on the wrapped request object.
 HttpSession HttpServletRequest.getSession(boolean create)
          Returns the current HttpSession associated with this request or, if there is no current session and create is true, returns a new session.
 HttpSession HttpSessionContext.getSession(String sessionId)
          已过时。 As of Java Servlet API 2.1 with no replacement. This method must return null and will be removed in a future version of this API.
 

参数类型为 HttpSessionjavax.servlet.http 中的构造方法
HttpSessionBindingEvent(HttpSession session, String name)
          Constructs an event that notifies an object that it has been bound to or unbound from a session.
HttpSessionBindingEvent(HttpSession session, String name, Object value)
          Constructs an event that notifies an object that it has been bound to or unbound from a session.
HttpSessionEvent(HttpSession source)
          Construct a session event from the given source.
 

javax.servlet.jspHttpSession 的使用
 

返回 HttpSessionjavax.servlet.jsp 中的方法
abstract  HttpSession PageContext.getSession()
          The current value of the session object (an HttpSession).
 

org.apache.jasper.runtimeHttpSession 的使用
 

返回 HttpSessionorg.apache.jasper.runtime 中的方法
 HttpSession PageContextImpl.getSession()
           
 HttpSession JspContextWrapper.getSession()
           
 

org.eclipse.jetty.security.authenticationHttpSession 的使用
 

返回 HttpSessionorg.eclipse.jetty.security.authentication 中的方法
protected  HttpSession LoginAuthenticator.renewSession(HttpServletRequest request, HttpServletResponse response)
          Change the session id.
 

org.eclipse.jetty.serverHttpSession 的使用
 

返回 HttpSessionorg.eclipse.jetty.server 中的方法
 HttpSession SessionManager.getHttpSession(String id)
          Returns the HttpSession with the given session id
 HttpSession ServletRequestHttpWrapper.getSession()
           
 HttpSession Request.getSession()
           
 HttpSession ServletRequestHttpWrapper.getSession(boolean create)
           
 HttpSession Request.getSession(boolean create)
           
 HttpSession SessionManager.newHttpSession(HttpServletRequest request)
          Creates a new HttpSession.
 HttpSession Request.recoverNewSession(Object key)
           
 

参数类型为 HttpSessionorg.eclipse.jetty.server 中的方法
 HttpCookie SessionManager.access(HttpSession session, boolean secure)
          Called by the SessionHandler when a session is first accessed by a request.
 void SessionIdManager.addSession(HttpSession session)
          Add a session to the list of known sessions for a given ID.
 void SessionManager.complete(HttpSession session)
          Called by the SessionHandler when a session is last accessed by a request.
 String SessionManager.getClusterId(HttpSession session)
           
 String SessionManager.getNodeId(HttpSession session)
           
 HttpCookie SessionManager.getSessionCookie(HttpSession session, String contextPath, boolean requestIsSecure)
          Gets a Cookie for a session.
 boolean SessionManager.isValid(HttpSession session)
           
 void SessionIdManager.removeSession(HttpSession session)
          Remove session from the list of known sessions for a given ID.
 void Request.saveNewSession(Object key, HttpSession session)
           
 void Request.setSession(HttpSession session)
           
 

org.eclipse.jetty.server.sessionHttpSession 的使用
 

org.eclipse.jetty.server.sessionHttpSession 的子接口
static interface AbstractSessionManager.SessionIf
          Interface that any session wrapper should implement so that SessionManager may access the Jetty session implementation.
 

实现 HttpSessionorg.eclipse.jetty.server.session 中的类
 class AbstractSession
           Implements HttpSession from the javax.servlet package.
 class HashedSession
           
 class JDBCSessionManager.Session
          Session Session instance.
 

返回 HttpSessionorg.eclipse.jetty.server.session 中的方法
 HttpSession AbstractSessionManager.getHttpSession(String nodeId)
           
 HttpSession AbstractSessionManager.newHttpSession(HttpServletRequest request)
          Create a new HttpSession for a request
static HttpSession AbstractSessionManager.renewSession(HttpServletRequest request, HttpSession httpSession, boolean authenticated)
           
 

返回变量类型为 HttpSession 的类型的 org.eclipse.jetty.server.session 中的方法
 Collection<HttpSession> HashSessionIdManager.getSession(String id)
           
 

参数类型为 HttpSessionorg.eclipse.jetty.server.session 中的方法
 HttpCookie AbstractSessionManager.access(HttpSession session, boolean secure)
           
 void JDBCSessionIdManager.addSession(HttpSession session)
           
 void HashSessionIdManager.addSession(HttpSession session)
           
 void AbstractSessionManager.complete(HttpSession session)
           
 String AbstractSessionManager.getClusterId(HttpSession session)
           
 String AbstractSessionManager.getNodeId(HttpSession session)
           
 HttpCookie AbstractSessionManager.getSessionCookie(HttpSession session, String contextPath, boolean requestIsSecure)
          A sessioncookie is marked as secure IFF any of the following conditions are true: SessionCookieConfig.setSecure == true SessionCookieConfig.setSecure == false && _secureRequestOnly==true && request is HTTPS According to SessionCookieConfig javadoc, case 1 can be used when: "... even though the request that initiated the session came over HTTP, is to support a topology where the web container is front-ended by an SSL offloading load balancer.
 boolean AbstractSessionManager.isValid(HttpSession session)
           
 void JDBCSessionIdManager.removeSession(HttpSession session)
           
 void HashSessionIdManager.removeSession(HttpSession session)
           
 void AbstractSessionManager.removeSession(HttpSession session, boolean invalidate)
          Remove session from manager
static HttpSession AbstractSessionManager.renewSession(HttpServletRequest request, HttpSession httpSession, boolean authenticated)
           
 



Copyright © 2013. All Rights Reserved.