org.apache.lenya.ac.file
Class FileGroup

java.lang.Object
  extended by org.apache.avalon.framework.logger.AbstractLogEnabled
      extended by org.apache.lenya.ac.impl.AbstractItem
          extended by org.apache.lenya.ac.impl.AbstractGroup
              extended by org.apache.lenya.ac.file.FileGroup
All Implemented Interfaces:
java.lang.Comparable, org.apache.avalon.framework.logger.LogEnabled, org.apache.lenya.ac.Accreditable, org.apache.lenya.ac.Group, org.apache.lenya.ac.Identifiable, org.apache.lenya.ac.Item

public class FileGroup
extends AbstractGroup
implements org.apache.lenya.ac.Item

File-based group implementation.


Field Summary
static java.lang.String GROUP
          Group configuration element.
 
Constructor Summary
FileGroup(org.apache.lenya.ac.ItemManager itemManager, org.apache.avalon.framework.logger.Logger logger)
          Creates a new FileGroup object.
FileGroup(org.apache.lenya.ac.ItemManager itemManager, org.apache.avalon.framework.logger.Logger logger, java.lang.String id)
          Create a new instance of FileGroup
 
Method Summary
 void configure(org.apache.avalon.framework.configuration.Configuration config)
          Configures this file group.
 void delete()
          Delete a group
protected  java.io.File getConfigurationDirectory()
          Returns the configuration directory.
protected  java.io.File getFile()
          Returns the configuration file.
 void save()
          Save this group
protected  void setConfigurationDirectory(java.io.File _configurationDirectory)
           
 
Methods inherited from class org.apache.lenya.ac.impl.AbstractGroup
add, contains, getAccreditables, getMembers, remove, removeAllMembers
 
Methods inherited from class org.apache.lenya.ac.impl.AbstractItem
compareTo, equals, getAccreditableManager, getDescription, getId, getItemManager, getName, hashCode, setDescription, setId, setName, toString
 
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.apache.lenya.ac.Item
getDescription, getId, getItemManager, getName, setDescription, setName
 
Methods inherited from interface org.apache.avalon.framework.logger.LogEnabled
enableLogging
 

Field Detail

GROUP

public static final java.lang.String GROUP
Group configuration element.

See Also:
Constant Field Values
Constructor Detail

FileGroup

public FileGroup(org.apache.lenya.ac.ItemManager itemManager,
                 org.apache.avalon.framework.logger.Logger logger)
Creates a new FileGroup object.

Parameters:
itemManager - The item manager.
logger - The logger.

FileGroup

public FileGroup(org.apache.lenya.ac.ItemManager itemManager,
                 org.apache.avalon.framework.logger.Logger logger,
                 java.lang.String id)
Create a new instance of FileGroup

Parameters:
itemManager - The item manager.
logger - The logger.
id - the ID of the group
Method Detail

delete

public void delete()
            throws org.apache.lenya.ac.AccessControlException
Description copied from class: AbstractGroup
Delete a group

Specified by:
delete in interface org.apache.lenya.ac.Group
Overrides:
delete in class AbstractGroup
Throws:
org.apache.lenya.ac.AccessControlException - if the delete failed
See Also:
Group.delete()

configure

public void configure(org.apache.avalon.framework.configuration.Configuration config)
               throws org.apache.avalon.framework.configuration.ConfigurationException
Configures this file group.

Specified by:
configure in interface org.apache.lenya.ac.Item
Parameters:
config - The configuration.
Throws:
org.apache.avalon.framework.configuration.ConfigurationException - when something went wrong.

getFile

protected java.io.File getFile()
Returns the configuration file.

Returns:
A file object.

save

public void save()
          throws org.apache.lenya.ac.AccessControlException
Save this group

Specified by:
save in interface org.apache.lenya.ac.Group
Throws:
org.apache.lenya.ac.AccessControlException - if the save failed

getConfigurationDirectory

protected java.io.File getConfigurationDirectory()
Returns the configuration directory.

Returns:
A file object.

setConfigurationDirectory

protected void setConfigurationDirectory(java.io.File _configurationDirectory)


Copyright $ Apache Software Foundation. All Rights Reserved.