org.openpermis.editor.policy.configuration
Class ConfigurationSectionTrader

java.lang.Object
  extended by org.openpermis.editor.policy.configuration.ConfigurationSectionTrader
All Implemented Interfaces:
ConfigurationSectionFactory

public class ConfigurationSectionTrader
extends Object
implements ConfigurationSectionFactory

Trader for multiple configuration section factories.

Since:
0.9.0

Constructor Summary
ConfigurationSectionTrader()
          Creates a new initially empty trader.
 
Method Summary
protected  void addFactory(ConfigurationSectionFactory factory)
          Adds the specified factory to the list of factories.
 void addGenericFactory(String name, boolean caching)
          Adds a generic section factory for elements with the specified name.
 void addGroupFactory(String name)
          Adds a group section factory for elements with the specified name.
 void addScopedFactory(String name, Class<?> scope)
          Adds a scoped section factory for elements with the specified name.
 ConfigurationSection createSection(org.dom4j.Element element)
          Creates a configuration section for the specified element.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConfigurationSectionTrader

public ConfigurationSectionTrader()
Creates a new initially empty trader.

Since:
0.9.0
Method Detail

addGroupFactory

public void addGroupFactory(String name)
Adds a group section factory for elements with the specified name.

Parameters:
name - the name of the element to match.
Since:
0.9.0

addGenericFactory

public void addGenericFactory(String name,
                              boolean caching)
Adds a generic section factory for elements with the specified name.

Parameters:
name - the name of the element to match.
caching - indicates if the configuration section is created with caching or not.
Since:
0.9.0

addScopedFactory

public void addScopedFactory(String name,
                             Class<?> scope)
Adds a scoped section factory for elements with the specified name.

Parameters:
name - the name of the element to match.
scope - the scope class for child implementations.
Since:
0.9.0

addFactory

protected void addFactory(ConfigurationSectionFactory factory)
Adds the specified factory to the list of factories.

Parameters:
factory - the factory to add.
Since:
0.9.0

createSection

public ConfigurationSection createSection(org.dom4j.Element element)
Description copied from interface: ConfigurationSectionFactory
Creates a configuration section for the specified element.

Specified by:
createSection in interface ConfigurationSectionFactory
Parameters:
element - the element to create the section for, must not be null.
Returns:
the configuration section requested or null if this factory cannot create a section for this element.
Since:
0.9.0


OpenPermis Role Based Access Control 0.9.0 (Build 16)
2009/08/13 07:17:21
Copyright (c) 2002-2007 Ergon Informatik AG