Save This Page
Home » apache-tomcat-6.0.16-src » org.apache » catalina » session » [javadoc | source]
org.apache.catalina.session
public final class: FileStore [javadoc | source]
java.lang.Object
   org.apache.catalina.session.StoreBase
      org.apache.catalina.session.FileStore

All Implemented Interfaces:
    Store, Lifecycle

Concrete implementation of the Store interface that utilizes a file per saved Session in a configured directory. Sessions that are saved are still subject to being expired based on inactivity.
Fields inherited from org.apache.catalina.session.StoreBase:
info,  storeName,  started,  lifecycle,  support,  sm,  manager
Method from org.apache.catalina.session.FileStore Summary:
clear,   getDirectory,   getInfo,   getSize,   getStoreName,   getThreadName,   keys,   load,   remove,   save,   setDirectory
Methods from org.apache.catalina.session.StoreBase:
addLifecycleListener,   addPropertyChangeListener,   findLifecycleListeners,   getInfo,   getManager,   getStoreName,   processExpires,   removeLifecycleListener,   removePropertyChangeListener,   setManager,   start,   stop
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.catalina.session.FileStore Detail:
 public  void clear() throws IOException 
    Remove all of the Sessions in this Store.
 public String getDirectory() 
    Return the directory path for this Store.
 public String getInfo() 
    Return descriptive information about this Store implementation and the corresponding version number, in the format <description>/<version>.
 public int getSize() throws IOException 
    Return the number of Sessions present in this Store.
 public String getStoreName() 
    Return the name for this Store, used for logging.
 public String getThreadName() 
    Return the thread name for this Store.
 public String[] keys() throws IOException 
    Return an array containing the session identifiers of all Sessions currently saved in this Store. If there are no such Sessions, a zero-length array is returned.
 public Session load(String id) throws IOException, ClassNotFoundException 
    Load and return the Session associated with the specified session identifier from this Store, without removing it. If there is no such stored Session, return null.
 public  void remove(String id) throws IOException 
    Remove the Session with the specified session identifier from this Store, if present. If no such Session is present, this method takes no action.
 public  void save(Session session) throws IOException 
    Save the specified Session into this Store. Any previously saved information for the associated session identifier is replaced.
 public  void setDirectory(String path) 
    Set the directory path for this Store.