com.cafesoft.cams.access
Interface AccessControlRulePersistenceManager

All Known Implementing Classes:
AbstractAccessControlRulePersistenceManager

public interface AccessControlRulePersistenceManager

AccessControlRulePersistenceManager defines the interface for classes that load, store, create, and remove AccessControlRule instances. A class implementing this iterface is registered for each AccessControlRule and is invoked during AccessControlPolicy loading, saving, and editing to manage the AccessControlRules within it.


Method Summary
 AccessControlRule acrCreate()
          Create a new/empty AccessControlRule.
 AccessControlRule acrLoad(Object object)
          Load an AccessControlRule from persistent storage.
 void acrRemove(AccessControlRule acr)
          Remove an AccessControlRule from persistent storage.
 void acrStore(AccessControlRule acr, Object dest)
          Store an AccessControlRule to persistent storage.
 void initialize(Config config)
          Initialize the AccessControlRulePersistenceManager.
 

Method Detail

initialize

public void initialize(Config config)
                throws ConfigException
Initialize the AccessControlRulePersistenceManager.

Parameters:
config - the configuration object through which parameters and context are available.
Throws:
ConfigException - if an error initializing this AccessControlRulePersistenceManager.

acrCreate

public AccessControlRule acrCreate()
Create a new/empty AccessControlRule.

Returns:
a new/empty AccessControlRule instance.

acrLoad

public AccessControlRule acrLoad(Object object)
                          throws PersistenceException
Load an AccessControlRule from persistent storage.

Parameters:
object - the Object referencing the AccessControlRule to be created. This may be a String, and XML DOM Element, or any other Object suitable for the storage location of the AccessControlRule.
Returns:
the AccessControlRule instance.
Throws:
PersistenceException - if an error creating the new AccessControlRule.
IllegalArgumentException - if the parameter is null or it's type is not supported by the factory implementation.

acrStore

public void acrStore(AccessControlRule acr,
                     Object dest)
              throws PersistenceException
Store an AccessControlRule to persistent storage.

Parameters:
acr - the AccessControlRule to be stored.
dest - an object that may be needed for some AccessControlRule storage destination types. For example, if the AccessControlRule is a file, then a PrintStream might be provided. Some storage destinations (e.g. a relational database), may not use this parameter.
Throws:
PersistenceException - if an error storing the AccessControlRule.
IllegalArgumentException - if a required parameter is null, or it's type is not supported by the implementation.

acrRemove

public void acrRemove(AccessControlRule acr)
               throws PersistenceException
Remove an AccessControlRule from persistent storage.

Parameters:
acr - the AccessControlRule to be removed from persistent storage.
Returns:
the AccessControlRule instance.
Throws:
PersistenceException - if an error creating the new AccessControlRule.
IllegalArgumentException - if the parameter is null or it's type is not supported by the factory implementation.


Generated on 5:16:42 PM May 12, 2008, © 1996-2005 Cafésoft LLC. All rights reserved.