Xindice API

org.apache.xindice.server
Interface ResourceManager

All Known Implementing Classes:
StdResourceManager

public interface ResourceManager

ResourceManager is an interface that is implemented to manage shared resources. Implementations are responsible for managing these objects in a custom-fashion. StdResourceManager is the standard implementation of this interface.

See Also:
StdResourceManager

Method Summary
 java.lang.Object getResource(java.lang.String name)
          getResource retrieves a resource by name from the ResourceManager.
 java.lang.Object getResource(Versioning versioning, java.lang.String name)
          getResource retrieves a resource by name from the ResourceManager.
 void lockResource(java.lang.String name)
          lockResource locks a resource by name in the ResourceManager.
 void lockResource(Versioning versioning, java.lang.String name)
          lockResource locks a resource by name in the ResourceManager.
 void removeResource(java.lang.String name)
          removeResource removes a resource by name from the ResourceManager.
 void removeResource(Versioning versioning, java.lang.String name)
          removeResource removes a resource by name from the ResourceManager.
 void setResource(java.lang.String name, java.lang.Object object)
          setResource places a resource by name into the ResourceManager.
 void setResource(Versioning versioning, java.lang.String name, java.lang.Object object)
          setResource places a resource by name into the ResourceManager.
 void unlockResource(java.lang.String name)
          unlockResource unlocks a resource by name in the ResourceManager.
 void unlockResource(Versioning versioning, java.lang.String name)
          unlockResource unlocks a resource by name in the ResourceManager.
 

Method Detail

setResource

public void setResource(Versioning versioning,
                        java.lang.String name,
                        java.lang.Object object)
                 throws ParameterException
setResource places a resource by name into the ResourceManager. The resource will be placed into the name space for the provided Versioning object.
Parameters:
versioning - the version space to use
name - the resource name
object - the object resource
Throws:
ParameterException - if the object cannot be stored

setResource

public void setResource(java.lang.String name,
                        java.lang.Object object)
                 throws ParameterException
setResource places a resource by name into the ResourceManager. The resource will be placed into the default name space.
Parameters:
name - the resource name
object - the object resource
Throws:
ParameterException - if the object cannot be stored

removeResource

public void removeResource(Versioning versioning,
                           java.lang.String name)
removeResource removes a resource by name from the ResourceManager. The resource will be removed from the name space for the provided Versioning object.
Parameters:
versioning - the version space to use
name - the resource name

removeResource

public void removeResource(java.lang.String name)
removeResource removes a resource by name from the ResourceManager. The resource will be removed from the default name space.
Parameters:
name - the resource name

getResource

public java.lang.Object getResource(Versioning versioning,
                                    java.lang.String name)
getResource retrieves a resource by name from the ResourceManager. The resource will be retrived from the name space for the provided Versioning object.
Parameters:
versioning - the version space to use
name - the resource name
Returns:
the object resource

getResource

public java.lang.Object getResource(java.lang.String name)
getResource retrieves a resource by name from the ResourceManager. The resource will be retrived from the default name space.
Parameters:
name - the resource name
Returns:
the object resource

lockResource

public void lockResource(Versioning versioning,
                         java.lang.String name)
lockResource locks a resource by name in the ResourceManager. Locking protects the resource from being overwritten or vulturized by the ResourceManager's dead object collector. The resource will be locked in the name space for the provided Versioning object.
Parameters:
versioning - the version space to use
name - the resource name

lockResource

public void lockResource(java.lang.String name)
lockResource locks a resource by name in the ResourceManager. Locking protects the resource from being overwritten or vulturized by the ResourceManager's dead object collector. The resource will be locked in the default name space.
Parameters:
name - the resource name

unlockResource

public void unlockResource(Versioning versioning,
                           java.lang.String name)
unlockResource unlocks a resource by name in the ResourceManager. The resource will be locked in the name space for the provided Versioning object.
Parameters:
versioning - the version space to use
name - the resource name

unlockResource

public void unlockResource(java.lang.String name)
unlockResource unlocks a resource by name in the ResourceManager. The resource will be locked in the default name space.
Parameters:
name - the resource name

Xindice API

Copyright (c) 1999-2001 The Apache Software Foundation