02/28/2005
 

com.epicentric.metastore
Class MetaStore

java.lang.Object
  |
  +--com.epicentric.services.AbstractControllable
        |
        +--com.epicentric.metastore.MetaStore
All Implemented Interfaces:
Controllable, Service, com.epicentric.uid.internal.UniquelyIdentifiableManager

public abstract class MetaStore
extends AbstractControllable
implements com.epicentric.uid.internal.UniquelyIdentifiableManager, Service

The MetaStore is a hierarchical Java object repository. Currently it is implemented over a relational database. It consists of a filesystem-like tree of folders and documents.

MetaStoreFolders are accessed within the MetaStore by their path. Like a filesystem path, a MetaStore path is a list of folders separated by slashes (/). For instance, if a folder named "3" is a child of folder "2", which is itself a child of "1", then the path would be "/1/2/3/".

Each folder may also store any number of named string or integer properties.

MetaStoreDocuments are what information is stored in. Each MetaStoreDocument can store a single piece of data. This data can be a string, byte array, serializable java object, DOM Document, or the contents of a URL.

Along with its primary single piece of data, each document can also store any number of named string properties.

There can be different implementations of the MetaStore with different persistence mechanisms. For instance, one implementation may use a relational database, while another implementation may use LDAP.

The MetaStore is a Service (see com.epicentric.services.ServiceManager). This means there can be multiple MetaStores running in the system. This is not the same as different implementations of the MetaStore: there can be multiple instances of one implementation running. To get one of the MetaStores running in the system, use the static methods getDefaultMetaStore() or getMetaStore(String service_id).

See Also:
MetaStoreDocument, MetaStoreFolder, ServiceManager, MetaStore.getDefaultMetaStore(), MetaStore.getMetaStore(String)

Field Summary
static String BEAN_FOLDER_NAME
           
static String LOCAL_SYSTEM_SUB_FOLDER_NAME
           
static String PATH_SEPARATOR
           
static String ROOT_FOLDER
           
static String SERVICE_CODE
           
static String SYSTEM_FOLDER_NAME
           
static String WEBDATA_FOLDER_NAME
           
 
Fields inherited from class com.epicentric.services.AbstractControllable
controller
 
Constructor Summary
MetaStore()
           
 
Method Summary
 boolean absolutePath(String path)
          Return true if the given folder path is absolute to the root of the MetaStore folder system.
 String appendPath(String path, String append)
           
abstract  void clean()
          Removes deleted records and files At the moment, not transaction safe, so should be run with servers shut down
 void clearCache()
          Deprecated. since version 4.5
 void clearCacheRecursive(String path)
          Deprecated. since version 4.5
 void close()
          Deprecated. use stop() instead.
 MetaStoreDocument createDocument(String path, String name)
          Create a MetaStoreDocument with the given name in the folder at the given path.
 MetaStoreFolder createPath(String path)
          Creates a MetaStoreFolder unless it already exists.
 MetaStoreDocument[] findDocuments(String path, String propertyName, String propertyValue)
          Find all Documents in the MetaStoreFolder at the given path that contain the given property with the given value.
 MetaStoreFolder[] findFolders(String path, String propertyName, String propertyValue)
          Retrieve all subfolders of the MetaStoreFolder at the given path that contain the given property with the given value.
 MetaStoreFolder getBeanFolder()
          Get the folder reserved for storing admin-level information about beans.
static MetaStore getDefaultMetaStore()
          Return the default MetaStore service.
static MetaStoreFolder getDefaultMetaStoreRootFolder()
          Returns the root folder of the default MetaStore.
 String getDescription()
          Retrieves the service description.
 MetaStoreDocument getDocument(String path, String name)
          Retrieve MetaStoreDocument with the given name in the folder at the given path.
abstract  MetaStoreDocument getDocument(String path, String name, boolean create)
          Retrieve the document with the given path and name.
protected  String getDocumentUIDType()
           
 MetaStoreFolder getFolder(String path)
          Returns the MetaStoreFolder at the given path.
abstract  MetaStoreFolder getFolder(String path, boolean create)
          Returns the MetaStoreFolder at the given path.
protected  String getFolderUIDType()
           
 String getID()
          Retrieves the service ID.
 String getLastFolderName(String path)
          Return terminal folder name in String.
 MetaStoreFolder getLocalSystemFolder()
          Return the folder reserved for setting local system properties.
static MetaStore getMetaStore(String id)
          Return the MetaStore service with the given service id.
 String getName()
          Retrieves the service name.
 String getParentPath(String path)
          Return the parent folder path of the given path.
 String[] getPathFolderNames(String path)
          Return array of all the folder names in the given path.
abstract  MetaStoreFolder getRootFolder()
          Returns the root folder.
 String getServiceInfo()
          Retrieves hard-coded information about the service.
 MetaStoreDocument getSessionDocument(User user)
          Deprecated.  
 MetaStoreDocument getSessionDocument(User user, String name)
          Deprecated.  
 MetaStoreFolder getSessionFolder(User user)
          Deprecated.  
 long getSessionID(User user)
          Deprecated.  
 Collection getSupportedUIDTypes()
          Returns a collection of the types that the manager supports.
 MetaStoreFolder getSystemFolder()
          Return the folder reserved for setting system properties.
 WebData getWebData(String url)
          Return a WebData representing the given URL.
 WebData getWebData(String url, int expire_age)
          Return a WebData representing the given URL.
 WebData getWebData(String url, int expire_age, boolean cache)
          Deprecated. since version 4.5. Use #getWebData(String,int) instead.
 WebData getWebData(URL url)
          Return a WebData representing the given URL.
 WebData getWebData(URL url, int expire_age)
          Return a WebData representing the given URL.
 WebData getWebData(URL url, int expire_age, boolean cache)
          Deprecated. since version 4.5. Use #getWebData(URL,int) instead.
 MetaStoreDocument getWebDocument(String url)
          Return a MetaStoreDocument representing the given URL.
 MetaStoreDocument getWebDocument(String url, int expire_age)
          Return a MetaStoreDocument representing the given URL.
 MetaStoreDocument getWebDocument(String url, int expire_age, boolean cache)
          Deprecated. since version 4.5. Use #getWebDocument(String,int) instead.
 MetaStoreDocument getWebDocument(URL url)
          Return a MetaStoreDocument representing the given URL.
 MetaStoreDocument getWebDocument(URL url, int expire_age)
          Return a MetaStoreDocument representing the given URL.
 MetaStoreDocument getWebDocument(URL url, int expire_age, boolean cache)
          Deprecated. since version 4.5. Use #getWebDocument(URL,int) instead.
 void init(ServiceConfig config)
          Initializes the service.
 MetaStoreFolder mount(String path, MetaStore store)
          Deprecated. As of 4.1, to be removed in 8.0 or later
 MetaStoreFolder mount(String path, MetaStoreFolder folder)
          Deprecated. As of 4.1, to be removed in 8.0 or later
 String normalizePath(String path)
          Normalize the syntax of the folder path.
 void open()
          Deprecated. use start() instead.
 boolean pathExists(String path)
          Return true if there's a MetaStoreFolder at the given path.
 void registerCacheClearingTrigger(javax.servlet.http.HttpSession session, String path)
          Deprecated. 4.1. To be removed in 8.0 or later
 void removePath(String path)
          Removes the MetaStoreFolder from the database and deletes all associated documents and values,
 void restart()
          Runs stop() and then start().
 void stop()
          Stops the service.
 MetaStoreDocument storeBytes(String path, String name, Byte[] data)
          Same as storeDocument(String, String, Byte[]).
 MetaStoreDocument storeDocument(String path, String name, Byte[] data)
          Create or retrieve the document with given name and path.
 MetaStoreDocument storeDocument(String path, String name, Node node)
          Create or retrieve the document with given name and path.
 MetaStoreDocument storeDocument(String path, String name, Object object)
          Create or retrieve the document with given name and path.
 MetaStoreDocument storeDocument(String path, String name, String text)
          Create or retrieve the document with given name and path.
 MetaStoreDocument storeDocument(String path, String name, URL url)
          Create or retrieve the document with given name and path.
 MetaStoreDocument storeNode(String path, String name, Node node)
          Same as storeDocument(String, String, Node).
 MetaStoreDocument storeObject(String path, String name, Object object)
          Same as storeDocument(String, String, Object).
 MetaStoreDocument storeString(String path, String name, String text)
          Same as storeDocument(String, String, String).
 MetaStoreDocument storeURL(String path, String name, URL url)
          Same as storeDocument(String, String, URL).
 void unmount(MetaStoreFolder folder)
          Deprecated. As of 4.1, to be removed in 8.0 or later
 void unmount(String path)
          Deprecated. As of 4.1, to be removed in 8.0 or later
 
Methods inherited from class com.epicentric.services.AbstractControllable
createController, getServiceController, init, start
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.epicentric.uid.internal.UniquelyIdentifiableManager
deleteObjectFromUID, getObjectFromUID
 
Methods inherited from interface com.epicentric.services.Service
start
 

Field Detail

SYSTEM_FOLDER_NAME

public static final String SYSTEM_FOLDER_NAME

BEAN_FOLDER_NAME

public static final String BEAN_FOLDER_NAME

WEBDATA_FOLDER_NAME

public static final String WEBDATA_FOLDER_NAME

LOCAL_SYSTEM_SUB_FOLDER_NAME

public static final String LOCAL_SYSTEM_SUB_FOLDER_NAME

PATH_SEPARATOR

public static final String PATH_SEPARATOR

ROOT_FOLDER

public static final String ROOT_FOLDER

SERVICE_CODE

public static final String SERVICE_CODE
Constructor Detail

MetaStore

public MetaStore()
Method Detail

getDefaultMetaStore

public static MetaStore getDefaultMetaStore()
Return the default MetaStore service.

getMetaStore

public static MetaStore getMetaStore(String id)
Return the MetaStore service with the given service id.

For instance, the service id "default" would get the MetaStore configured with the properties in the properties file starting with "metastore.default".

getDefaultMetaStoreRootFolder

public static MetaStoreFolder getDefaultMetaStoreRootFolder()
Returns the root folder of the default MetaStore.
See Also:
MetaStore.getDefaultMetaStore()

registerCacheClearingTrigger

public final void registerCacheClearingTrigger(javax.servlet.http.HttpSession session,
                                               String path)
Deprecated. 4.1. To be removed in 8.0 or later


open

public final void open()
Deprecated. use start() instead.

Start up this MetaStore.

close

public final void close()
Deprecated. use stop() instead.

Shut down this MetaStore, close all database connections.

getRootFolder

public abstract MetaStoreFolder getRootFolder()
Returns the root folder. The root folder contains all other folders in the MetaStore.

getSystemFolder

public MetaStoreFolder getSystemFolder()
Return the folder reserved for setting system properties.

getLocalSystemFolder

public MetaStoreFolder getLocalSystemFolder()
Return the folder reserved for setting local system properties.

getBeanFolder

public MetaStoreFolder getBeanFolder()
Get the folder reserved for storing admin-level information about beans. Note that a nice bean will not store info directly in this folder, but create a subfolder with the same name as the bean. For instance, the newsbean might do:
   folder = getBeanFolder()
   folder.getFolder("newsbean", true);
 
Note that user-specific info is NOT stored here: PortalBeanView.getFolder() contains the algorithm for storing user-specific info.
See Also:
PortalBeanView.getFolder()

getFolder

public MetaStoreFolder getFolder(String path)
Returns the MetaStoreFolder at the given path.

getFolder

public abstract MetaStoreFolder getFolder(String path,
                                          boolean create)
Returns the MetaStoreFolder at the given path.
Parameters:
create - If true, creates the folder if it doesn't exist.

findFolders

public MetaStoreFolder[] findFolders(String path,
                                     String propertyName,
                                     String propertyValue)
Retrieve all subfolders of the MetaStoreFolder at the given path that contain the given property with the given value.

pathExists

public boolean pathExists(String path)
Return true if there's a MetaStoreFolder at the given path.

createPath

public MetaStoreFolder createPath(String path)
Creates a MetaStoreFolder unless it already exists.
Returns:
null if path cannot be created

removePath

public void removePath(String path)
Removes the MetaStoreFolder from the database and deletes all associated documents and values,

mount

public final MetaStoreFolder mount(String path,
                                   MetaStore store)
Deprecated. As of 4.1, to be removed in 8.0 or later

Mounts the specified MetaStore at the given path.

mount

public final MetaStoreFolder mount(String path,
                                   MetaStoreFolder folder)
Deprecated. As of 4.1, to be removed in 8.0 or later

Mounts the specified MetaStoreFolder at the given path.

unmount

public final void unmount(String path)
Deprecated. As of 4.1, to be removed in 8.0 or later

Unmounts the specified MetaStore at the given path.

unmount

public final void unmount(MetaStoreFolder folder)
Deprecated. As of 4.1, to be removed in 8.0 or later

Unmounts the specified MetaStoreFolder.

createDocument

public MetaStoreDocument createDocument(String path,
                                        String name)
Create a MetaStoreDocument with the given name in the folder at the given path. If the document already exists, does not re-create it.
Parameters:
path - Path of folder in which document lives.
name - Name of document to get.

getDocument

public MetaStoreDocument getDocument(String path,
                                     String name)
Retrieve MetaStoreDocument with the given name in the folder at the given path. Does not create it if it doesn't exist.
Parameters:
path - Path of folder in which document lives.
name - Name of document to get.

getDocument

public abstract MetaStoreDocument getDocument(String path,
                                              String name,
                                              boolean create)
Retrieve the document with the given path and name. If create == true, create document if it doesn't exist. If the document exists, but has expired, I destroy the document. Then, if create == true, I recreate it.
Parameters:
path - Path of folder in which document lives.
name - Name of document to get.
create - If true, create document if it doesn't exist.
See Also:
MetaStoreDocument.setExpiration(int)

storeDocument

public MetaStoreDocument storeDocument(String path,
                                       String name,
                                       Node node)
Create or retrieve the document with given name and path. Set contents of document to given Node. Persistify.

storeDocument

public MetaStoreDocument storeDocument(String path,
                                       String name,
                                       String text)
Create or retrieve the document with given name and path. Set contents of document to given text. Persistify.

storeDocument

public MetaStoreDocument storeDocument(String path,
                                       String name,
                                       Object object)
Create or retrieve the document with given name and path. Set contents of document to given Object. Persistify.

storeDocument

public MetaStoreDocument storeDocument(String path,
                                       String name,
                                       Byte[] data)
Create or retrieve the document with given name and path. Set contents of document to given bytes. Persistify.

storeDocument

public MetaStoreDocument storeDocument(String path,
                                       String name,
                                       URL url)
Create or retrieve the document with given name and path. Set contents of document to contents of given URL. Persistify. Always downloads the contents of the URL, even if document already existed and had the contents of the given URL. Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
path - Path of folder containing document.
name - Name of document.
url - URL of contents of document.

findDocuments

public MetaStoreDocument[] findDocuments(String path,
                                         String propertyName,
                                         String propertyValue)
Find all Documents in the MetaStoreFolder at the given path that contain the given property with the given value.

getWebData

public WebData getWebData(URL url)
Return a WebData representing the given URL. The WebData's contents are downloaded and persistified if they don't already exist. This is similar to calling getWebDocument(url).getWebData(). Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.

getWebData

public WebData getWebData(URL url,
                          int expire_age)
Return a WebData representing the given URL. The WebData's contents are downloaded and persistified if they don't already exist. This is similar to calling getWebDocument(url).getWebData(). Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.

getWebData

public WebData getWebData(URL url,
                          int expire_age,
                          boolean cache)
Deprecated. since version 4.5. Use #getWebData(URL,int) instead.

Return a WebData representing the given URL. The WebData's contents are downloaded and persistified if they don't already exist. This is similar to calling getWebDocument(url).getWebData(). Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.
cache - True: cache in memory permanently, even in low memory conditions.

getWebDocument

public MetaStoreDocument getWebDocument(URL url)
Return a MetaStoreDocument representing the given URL. The Document and the contents of the URL are downloaded and persistified if they don't already exist. Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return. Implementation note: this stores the contents of the URLs in the /webdata/ folder of the metastore.

getWebDocument

public MetaStoreDocument getWebDocument(URL url,
                                        int expire_age)
Return a MetaStoreDocument representing the given URL. The Document and the contents of the URL are downloaded and persistified if they don't already exist. Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.

getWebDocument

public MetaStoreDocument getWebDocument(URL url,
                                        int expire_age,
                                        boolean cache)
Deprecated. since version 4.5. Use #getWebDocument(URL,int) instead.

Return a MetaStoreDocument representing the given URL. The Document and the contents of the URL are downloaded and persistified if they don't already exist. Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.
cache - True: cache in memory permanently, even in low memory conditions.

clearCache

public final void clearCache()
Deprecated. since version 4.5

Clears the memory cache

clearCacheRecursive

public final void clearCacheRecursive(String path)
Deprecated. since version 4.5

Clears the memory cache from the provided path, recursively
Parameters:
path - The root of the path to clear the cache of.

clean

public abstract void clean()
Removes deleted records and files At the moment, not transaction safe, so should be run with servers shut down

storeNode

public MetaStoreDocument storeNode(String path,
                                   String name,
                                   Node node)
Same as storeDocument(String, String, Node). Provides non-overloaded method for use by Microsoft scripting environment, which can't handle methods overloaded with the same number of arguments.
See Also:
MetaStore.storeDocument(String, String, Node)

storeString

public MetaStoreDocument storeString(String path,
                                     String name,
                                     String text)
Same as storeDocument(String, String, String). Provides non-overloaded method for use by Microsoft scripting environment, which can't handle methods overloaded with the same number of arguments.
See Also:
MetaStore.storeDocument(String, String, String)

storeObject

public MetaStoreDocument storeObject(String path,
                                     String name,
                                     Object object)
Same as storeDocument(String, String, Object). Provides non-overloaded method for use by Microsoft scripting environment, which can't handle methods overloaded with the same number of arguments.
See Also:
MetaStore.storeDocument(String, String, Object)

storeBytes

public MetaStoreDocument storeBytes(String path,
                                    String name,
                                    Byte[] data)
Same as storeDocument(String, String, Byte[]). Provides non-overloaded method for use by Microsoft scripting environment, which can't handle methods overloaded with the same number of arguments.
See Also:
MetaStore.storeDocument(String, String, Byte[])

storeURL

public MetaStoreDocument storeURL(String path,
                                  String name,
                                  URL url)
Same as storeDocument(String, String, URL). Provides non-overloaded method for use by Microsoft scripting environment, which can't handle methods overloaded with the same number of arguments.
See Also:
MetaStore.storeDocument(String, String, URL)

getWebData

public WebData getWebData(String url)
Return a WebData representing the given URL. The WebData's contents are downloaded and persistified if they don't already exist. This is similar to calling getWebDocument(url).getWebData(). Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.

getWebData

public WebData getWebData(String url,
                          int expire_age)
Return a WebData representing the given URL. The WebData's contents are downloaded and persistified if they don't already exist. This is similar to calling getWebDocument(url).getWebData(). Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.

getWebData

public WebData getWebData(String url,
                          int expire_age,
                          boolean cache)
Deprecated. since version 4.5. Use #getWebData(String,int) instead.

Return a WebData representing the given URL. The WebData's contents are downloaded and persistified if they don't already exist. This is similar to calling getWebDocument(url).getWebData(). Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.
cache - True: cache in memory permanently, even in low memory conditions.

getWebDocument

public MetaStoreDocument getWebDocument(String url)
Return a MetaStoreDocument representing the given URL. The Document and the contents of the URL are downloaded and persistified if they don't already exist. Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return. Implementation note: this stores the contents of the URLs in the /webdata/ folder of the metastore.

getWebDocument

public MetaStoreDocument getWebDocument(String url,
                                        int expire_age)
Return a MetaStoreDocument representing the given URL. The Document and the contents of the URL are downloaded and persistified if they don't already exist. Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.

getWebDocument

public MetaStoreDocument getWebDocument(String url,
                                        int expire_age,
                                        boolean cache)
Deprecated. since version 4.5. Use #getWebDocument(String,int) instead.

Return a MetaStoreDocument representing the given URL. The Document and the contents of the URL are downloaded and persistified if they don't already exist. Note -- given the time it may take to download the contents of the URL, this method may take an extremely long time to return.
Parameters:
url - The URL whose contents the document will contain.
expire_age - Number of minutes to store contents of URL on local disk. When expired, getting the contents will trigger re-retrieval from the source host. Zero or less means to never refresh.
cache - True: cache in memory permanently, even in low memory conditions.

normalizePath

public String normalizePath(String path)
Normalize the syntax of the folder path. A normalized folder path always ends with "/". The root folder is "/".

appendPath

public String appendPath(String path,
                         String append)

absolutePath

public boolean absolutePath(String path)
Return true if the given folder path is absolute to the root of the MetaStore folder system.

getParentPath

public String getParentPath(String path)
Return the parent folder path of the given path. For instance, a path of "/folder_one/subfolder/" would return "/folder_one/". The parent path of the root folder is null. Paths that do not include a leading slash ["/"] will return a parent without a leading slash. Thus, "folder_one/subfolder/" would return "folder_one/" and "test_folder/" would return the empty string [""].

getLastFolderName

public String getLastFolderName(String path)
Return terminal folder name in String.

getPathFolderNames

public String[] getPathFolderNames(String path)
Return array of all the folder names in the given path. Element 0 is the root folder name. For instance, "a/b/c/" would result in a 3 element array whose 0th element would be "a".

getSessionFolder

public MetaStoreFolder getSessionFolder(User user)
Deprecated.  

Get the MetaStore folder used to store session data for a user. Creates the folder if it doesn't exist.

getSessionDocument

public MetaStoreDocument getSessionDocument(User user,
                                            String name)
Deprecated.  

Get the named MetaStore document in the user session folder. If the document doesn't exist, its created. The document returned has an expiration set for 20 minutes. Additional calls to this method will reset the expiration to 20 minutes so so that the session will always live for at least 20 minutes after this method is last called.

getSessionDocument

public MetaStoreDocument getSessionDocument(User user)
Deprecated.  

Get a document to store user session data in. The document returned has an expiration set for 20 minutes. Additional calls to this method will reset the expiration to 20 minutes so so that the session will always live for at least 20 minutes after this method is last called.

Session properties in a hashtable which is stored in this document.

Although inefficient, session data can also be stored as properties of this document rather than data in the document.

For example:

MetaStoreDocument session = store.getSessionDocument(user); String name = session.getProperty("name");


getSessionID

public long getSessionID(User user)
Deprecated.  

Get an identifier value for the current session. When the session expires, the identifier value is no longer valid. This allows authentication to take place where a user unique id and a session identifier might be passed in a url and when the script at that url is executed, it looks up the user using the unique id and then compares the current session identifier to the session identifier passed in the url. If they're different, then the URL was created in a previous expired session and the script might decide to have the user re-login.

getSupportedUIDTypes

public Collection getSupportedUIDTypes()
Description copied from interface: com.epicentric.uid.internal.UniquelyIdentifiableManager
Returns a collection of the types that the manager supports.
Specified by:
getSupportedUIDTypes in interface com.epicentric.uid.internal.UniquelyIdentifiableManager
Following copied from interface: com.epicentric.uid.internal.UniquelyIdentifiableManager
Returns:
Collection of String uid types

getFolderUIDType

protected String getFolderUIDType()

getDocumentUIDType

protected String getDocumentUIDType()

init

public void init(ServiceConfig config)
Deprecated. since version 4.5

Description copied from interface: Service
Initializes the service. Any initialization error conditions should be noted in the service's internal state.
Specified by:
init in interface Service
Following copied from interface: com.epicentric.services.Service
Parameters:
config - ServiceConfig for this Service

stop

public void stop()
Deprecated. since version 4.5

Description copied from interface: Service
Stops the service. (For some services, a null implementation is appropriate.)
Specified by:
stop in interface Service

restart

public void restart()
             throws ServiceException
Deprecated. since version 4.5

Description copied from interface: Service
Runs stop() and then start().
Specified by:
restart in interface Service

getServiceInfo

public String getServiceInfo()
Deprecated. since version 4.5. Instead use getServiceController().getServiceInfo()

Description copied from interface: Service
Retrieves hard-coded information about the service.
Specified by:
getServiceInfo in interface Service
Following copied from interface: com.epicentric.services.Service
Returns:
String description of the service.

getID

public String getID()
Deprecated. since version 4.5. Instead use getServiceController().getServiceConfiguration().getID()

Description copied from interface: Service
Retrieves the service ID.
Specified by:
getID in interface Service
Following copied from interface: com.epicentric.services.Service
Returns:
service's ID as defined in the properties file

getName

public String getName()
Deprecated. since version 4.5

Description copied from interface: Service
Retrieves the service name.
Specified by:
getName in interface Service
Following copied from interface: com.epicentric.services.Service
Returns:
service's name as defined in the properties file

getDescription

public String getDescription()
Deprecated. since version 4.5

Description copied from interface: Service
Retrieves the service description.
Specified by:
getDescription in interface Service
Following copied from interface: com.epicentric.services.Service
Returns:
service's description as defined in the properties file

02/28/2005
 

Copyright and Trademark Notices