| 
 |   | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
  |
  +--sunlabs.brazil.session.SessionManager
        |
        +--sunlabs.brazil.session.CacheManager
This SessionManager associates an object with a Session ID
 to give Handlers the ability to maintain state that lasts for the
 duration of a session instead of just for the duration of a request.
 It should be installed as a handler, whoses init method will replace
 the default session manager.
 
This version maintains a pool of hashtables. Once they all fill up - one of them gets tossed, causing any session info in it to be lost. It uses a simplified approximate LRU scheme. The default session manager doesn't loose any session information, but grows the heap without bound as the number of sessions increase.
properties:
| Constructor Summary | |
| CacheManager() | |
| Method Summary | |
|  boolean | init(Server server,
     String prefix)Install this class as the session manager. | 
|  void | removeObj(Object session,
          Object ident)Remove an object from a session table. | 
|  boolean | respond(Request request)Don't handle any URL requests (yet) | 
| Methods inherited from class sunlabs.brazil.session.SessionManager | 
| get, getSession, put, remove, setSessionManager | 
| Methods inherited from class java.lang.Object | 
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
public CacheManager()
| Method Detail | 
public boolean init(Server server,
                    String prefix)
init in interface Handlerserver - The HTTP server that created this Handler.
		Typical Handlers will use Server.props
		to obtain run-time configuration information.prefix - The handlers name.
		The string this Handler may prepend to all
		of the keys that it uses to extract configuration information
		from Server.props.  This is set (by the Server
		and ChainHandler) to help avoid configuration parameter
		namespace collisions.
true if this Handler initialized
		successfully, false otherwise.  If
		false is returned, this Handler
		should not be used.public boolean respond(Request request)
respond in interface Handlerrequest - The Request object that represents the HTTP
		request.
true if the request was handled.  A request was
		handled if a response was supplied to the client, typically
		by calling Request.sendResponse() or
		Request.sendError.
public void removeObj(Object session,
                      Object ident)
removeObj in class SessionManager| 
 | Version 2.1, Generated 12/30/04 Copyright (c) 2001-2004, Sun Microsystems. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||