org.apache.commons.configuration
Class ConfigurationFactory.FileConfigurationFactory

java.lang.Object
  extended byorg.apache.commons.digester.AbstractObjectCreationFactory
      extended byorg.apache.commons.configuration.ConfigurationFactory.DigesterConfigurationFactory
          extended byorg.apache.commons.configuration.ConfigurationFactory.FileConfigurationFactory
All Implemented Interfaces:
ObjectCreationFactory
Direct Known Subclasses:
ConfigurationFactory.PropertiesConfigurationFactory, ConfigurationFactory.PropertyListConfigurationFactory
Enclosing class:
ConfigurationFactory

public class ConfigurationFactory.FileConfigurationFactory
extends ConfigurationFactory.DigesterConfigurationFactory

A tiny inner class that allows the Configuration Factory to let the digester construct FileConfiguration objects that already have the correct base Path set.


Field Summary
 
Fields inherited from class org.apache.commons.digester.AbstractObjectCreationFactory
digester
 
Constructor Summary
ConfigurationFactory.FileConfigurationFactory(Class clazz)
          C'tor
 
Method Summary
protected  FileConfiguration createConfiguration(Attributes attributes)
          Creates the object, a FileConfiguration.
 Object createObject(Attributes attributes)
          Gets called by the digester.
 
Methods inherited from class org.apache.commons.digester.AbstractObjectCreationFactory
getDigester, setDigester
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConfigurationFactory.FileConfigurationFactory

public ConfigurationFactory.FileConfigurationFactory(Class clazz)
C'tor

Parameters:
clazz - The class which we should instantiate.
Method Detail

createObject

public Object createObject(Attributes attributes)
                    throws Exception
Gets called by the digester.

Specified by:
createObject in interface ObjectCreationFactory
Overrides:
createObject in class ConfigurationFactory.DigesterConfigurationFactory
Parameters:
attributes - the actual attributes
Returns:
the new object
Throws:
Exception - Couldn't instantiate the requested object.

createConfiguration

protected FileConfiguration createConfiguration(Attributes attributes)
                                         throws Exception
Creates the object, a FileConfiguration.

Parameters:
attributes - the actual attributes
Returns:
the file configuration
Throws:
Exception - if the object could not be created


Copyright © 2001-2006 The Apache Software Foundation. All Rights Reserved.