org.mortbay.jetty.servlet
Class AbstractSessionManager.Session

java.lang.Object
  extended by org.mortbay.jetty.servlet.AbstractSessionManager.Session
All Implemented Interfaces:
Serializable, HttpSession
Direct Known Subclasses:
HashSessionManager.Session
Enclosing class:
AbstractSessionManager

public abstract class AbstractSessionManager.Session
extends Object
implements HttpSession, Serializable

Implements HttpSession from the javax.servlet package.

Author:
gregw
See Also:
Serialized Form

Constructor Summary
protected AbstractSessionManager.Session(HttpServletRequest request)
           
protected AbstractSessionManager.Session(long created, String clusterId)
           
 
Method Summary
protected  void access(long time)
           
protected  void bindValue(String name, Object value)
          If value implements HttpSessionBindingListener, call valueBound()
protected  void complete()
           
protected  void cookieSet()
           
protected  void didActivate()
           
protected  void doInvalidate()
           
 Object getAttribute(String name)
           
 Enumeration getAttributeNames()
           
protected  String getClusterId()
           
 long getCookieSetTime()
           
 long getCreationTime()
           
 String getId()
           
 long getLastAccessedTime()
           
 int getMaxInactiveInterval()
           
protected  String getNodeId()
           
 ServletContext getServletContext()
           
 HttpSessionContext getSessionContext()
          Deprecated.  
 Object getValue(String name)
          Deprecated. As of Version 2.2, this method is replaced by getAttribute(java.lang.String)
 String[] getValueNames()
          Deprecated. As of Version 2.2, this method is replaced by getAttributeNames()
protected  void initValues()
           
 void invalidate()
           
 boolean isIdChanged()
           
 boolean isNew()
           
protected  boolean isValid()
           
protected abstract  Map newAttributeMap()
           
 void putValue(String name, Object value)
          Deprecated. As of Version 2.2, this method is replaced by setAttribute(java.lang.String, java.lang.Object)
 void removeAttribute(String name)
           
 void removeValue(String name)
          Deprecated. As of Version 2.2, this method is replaced by removeAttribute(java.lang.String)
 void setAttribute(String name, Object value)
           
 void setIdChanged(boolean changed)
           
 void setMaxInactiveInterval(int secs)
           
protected  void timeout()
           
 String toString()
           
protected  void unbindValue(String name, Object value)
          If value implements HttpSessionBindingListener, call valueUnbound()
protected  void willPassivate()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractSessionManager.Session

protected AbstractSessionManager.Session(HttpServletRequest request)

AbstractSessionManager.Session

protected AbstractSessionManager.Session(long created,
                                         String clusterId)
Method Detail

initValues

protected void initValues()

getAttribute

public Object getAttribute(String name)
Specified by:
getAttribute in interface HttpSession

getAttributeNames

public Enumeration getAttributeNames()
Specified by:
getAttributeNames in interface HttpSession

getCookieSetTime

public long getCookieSetTime()

getCreationTime

public long getCreationTime()
                     throws IllegalStateException
Specified by:
getCreationTime in interface HttpSession
Throws:
IllegalStateException

getId

public String getId()
             throws IllegalStateException
Specified by:
getId in interface HttpSession
Throws:
IllegalStateException

getNodeId

protected String getNodeId()

getClusterId

protected String getClusterId()

getLastAccessedTime

public long getLastAccessedTime()
                         throws IllegalStateException
Specified by:
getLastAccessedTime in interface HttpSession
Throws:
IllegalStateException

getMaxInactiveInterval

public int getMaxInactiveInterval()
Specified by:
getMaxInactiveInterval in interface HttpSession

getServletContext

public ServletContext getServletContext()
Specified by:
getServletContext in interface HttpSession

getSessionContext

public HttpSessionContext getSessionContext()
                                     throws IllegalStateException
Deprecated. 

Specified by:
getSessionContext in interface HttpSession
Throws:
IllegalStateException

getValue

public Object getValue(String name)
                throws IllegalStateException
Deprecated. As of Version 2.2, this method is replaced by getAttribute(java.lang.String)

Specified by:
getValue in interface HttpSession
Throws:
IllegalStateException

getValueNames

public String[] getValueNames()
                       throws IllegalStateException
Deprecated. As of Version 2.2, this method is replaced by getAttributeNames()

Specified by:
getValueNames in interface HttpSession
Throws:
IllegalStateException

access

protected void access(long time)

complete

protected void complete()

timeout

protected void timeout()
                throws IllegalStateException
Throws:
IllegalStateException

invalidate

public void invalidate()
                throws IllegalStateException
Specified by:
invalidate in interface HttpSession
Throws:
IllegalStateException

doInvalidate

protected void doInvalidate()
                     throws IllegalStateException
Throws:
IllegalStateException

isIdChanged

public boolean isIdChanged()

isNew

public boolean isNew()
              throws IllegalStateException
Specified by:
isNew in interface HttpSession
Throws:
IllegalStateException

putValue

public void putValue(String name,
                     Object value)
              throws IllegalStateException
Deprecated. As of Version 2.2, this method is replaced by setAttribute(java.lang.String, java.lang.Object)

Specified by:
putValue in interface HttpSession
Throws:
IllegalStateException

removeAttribute

public void removeAttribute(String name)
Specified by:
removeAttribute in interface HttpSession

removeValue

public void removeValue(String name)
                 throws IllegalStateException
Deprecated. As of Version 2.2, this method is replaced by removeAttribute(java.lang.String)

Specified by:
removeValue in interface HttpSession
Throws:
IllegalStateException

setAttribute

public void setAttribute(String name,
                         Object value)
Specified by:
setAttribute in interface HttpSession

setIdChanged

public void setIdChanged(boolean changed)

setMaxInactiveInterval

public void setMaxInactiveInterval(int secs)
Specified by:
setMaxInactiveInterval in interface HttpSession

toString

public String toString()
Overrides:
toString in class Object

bindValue

protected void bindValue(String name,
                         Object value)
If value implements HttpSessionBindingListener, call valueBound()


isValid

protected boolean isValid()

newAttributeMap

protected abstract Map newAttributeMap()

cookieSet

protected void cookieSet()

unbindValue

protected void unbindValue(String name,
                           Object value)
If value implements HttpSessionBindingListener, call valueUnbound()


willPassivate

protected void willPassivate()

didActivate

protected void didActivate()