public class DynamicCombinedConfiguration extends CombinedConfiguration
HierarchicalConfiguration.BuilderVisitor, HierarchicalConfiguration.Node, HierarchicalConfiguration.NodeVisitorEVENT_COMBINED_INVALIDATEEVENT_ADD_NODES, EVENT_CLEAR_TREE, EVENT_SUBNODE_CHANGEDEND_TOKEN, EVENT_ADD_PROPERTY, EVENT_CLEAR, EVENT_CLEAR_PROPERTY, EVENT_READ_PROPERTY, EVENT_SET_PROPERTY, START_TOKEN| Constructor and Description | 
|---|
| DynamicCombinedConfiguration()Creates a new instance of  DynamicCombinedConfigurationthat uses
 a union combiner. | 
| DynamicCombinedConfiguration(NodeCombiner comb)Creates a new instance of  DynamicCombinedConfigurationand
 initializes the combiner to be used. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | addConfiguration(AbstractConfiguration config,
                String name,
                String at)Adds a new configuration to this combined configuration. | 
| void | addConfigurationListener(ConfigurationListener l)Adds a configuration listener to this object. | 
| void | addErrorListener(ConfigurationErrorListener l)Adds a new configuration error listener to this object. | 
| void | addNodes(String key,
        Collection<? extends ConfigurationNode> nodes)Adds a collection of nodes at the specified position of the configuration
 tree. | 
| void | addProperty(String key,
           Object value)Add a property to the configuration. | 
| void | clear()Clears this configuration. | 
| void | clearConfigurationListeners()Removes all registered configuration listeners. | 
| void | clearErrorListeners()Removes all registered error listeners. | 
| void | clearProperty(String key)Removes the property with the given key. | 
| void | clearTree(String key)Removes all values of the property with the given name and of keys that
 start with this name. | 
| Object | clone()Returns a copy of this object. | 
| SubnodeConfiguration | configurationAt(String key)Returns a hierarchical subnode configuration for the node specified by
 the given key. | 
| SubnodeConfiguration | configurationAt(String key,
               boolean supportUpdates)
 Returns a hierarchical subnode configuration object that wraps the
 configuration node specified by the given key. | 
| List<HierarchicalConfiguration> | configurationsAt(String key)Returns a list of sub configurations for all configuration nodes selected
 by the given key. | 
| boolean | containsKey(String key)Checks if the specified key is contained in this configuration. | 
| BigDecimal | getBigDecimal(String key)Get a  BigDecimalassociated with the given configuration key. | 
| BigDecimal | getBigDecimal(String key,
             BigDecimal defaultValue)Get a  BigDecimalassociated with the given configuration key. | 
| BigInteger | getBigInteger(String key)Get a  BigIntegerassociated with the given configuration key. | 
| BigInteger | getBigInteger(String key,
             BigInteger defaultValue)Get a  BigIntegerassociated with the given configuration key. | 
| boolean | getBoolean(String key)Get a boolean associated with the given configuration key. | 
| boolean | getBoolean(String key,
          boolean defaultValue)Get a boolean associated with the given configuration key. | 
| Boolean | getBoolean(String key,
          Boolean defaultValue)Obtains the value of the specified key and tries to convert it into a
  Booleanobject. | 
| byte | getByte(String key)Get a byte associated with the given configuration key. | 
| byte | getByte(String key,
       byte defaultValue)Get a byte associated with the given configuration key. | 
| Byte | getByte(String key,
       Byte defaultValue)Get a  Byteassociated with the given configuration key. | 
| Configuration | getConfiguration(int index)Returns the configuration at the specified index. | 
| Configuration | getConfiguration(String name)Returns the configuration with the given name. | 
| Collection<ConfigurationListener> | getConfigurationListeners()Returns a collection with all configuration event listeners that are
 currently registered at this object. | 
| Set<String> | getConfigurationNames()Returns a set with the names of all configurations contained in this
 combined configuration. | 
| double | getDouble(String key)Get a double associated with the given configuration key. | 
| double | getDouble(String key,
         double defaultValue)Get a double associated with the given configuration key. | 
| Double | getDouble(String key,
         Double defaultValue)Get a  Doubleassociated with the given configuration key. | 
| Collection<ConfigurationErrorListener> | getErrorListeners()Returns a collection with all configuration error listeners that are
 currently registered at this object. | 
| ExpressionEngine | getExpressionEngine()Returns the expression engine used by this configuration. | 
| float | getFloat(String key)Get a float associated with the given configuration key. | 
| float | getFloat(String key,
        float defaultValue)Get a float associated with the given configuration key. | 
| Float | getFloat(String key,
        Float defaultValue)Get a  Floatassociated with the given configuration key. | 
| int | getInt(String key)Get a int associated with the given configuration key. | 
| int | getInt(String key,
      int defaultValue)Get a int associated with the given configuration key. | 
| Integer | getInteger(String key,
          Integer defaultValue)Get an  Integerassociated with the given configuration key. | 
| String | getKeyPattern() | 
| Iterator<String> | getKeys()Returns an iterator with all keys defined in this configuration. | 
| Iterator<String> | getKeys(String prefix)Returns an iterator with all keys defined in this configuration that
 start with the given prefix. | 
| List<Object> | getList(String key)Get a List of strings associated with the given configuration key. | 
| List<Object> | getList(String key,
       List<?> defaultValue)Get a List of strings associated with the given configuration key. | 
| long | getLong(String key)Get a long associated with the given configuration key. | 
| long | getLong(String key,
       long defaultValue)Get a long associated with the given configuration key. | 
| Long | getLong(String key,
       Long defaultValue)Get a  Longassociated with the given configuration key. | 
| int | getMaxIndex(String key)Returns the maximum defined index for the given key. | 
| NodeCombiner | getNodeCombiner()Returns the node combiner that is used for creating the combined node
 structure. | 
| int | getNumberOfConfigurations()Returns the number of configurations that are contained in this combined
 configuration. | 
| Properties | getProperties(String key)Get a list of properties associated with the given configuration key. | 
| Object | getProperty(String key)Fetches the specified property. | 
| HierarchicalConfiguration.Node | getRoot()Returns the root node of this hierarchical configuration. | 
| ConfigurationNode | getRootNode()Returns the configuration root node of this combined configuration. | 
| short | getShort(String key)Get a short associated with the given configuration key. | 
| short | getShort(String key,
        short defaultValue)Get a short associated with the given configuration key. | 
| Short | getShort(String key,
        Short defaultValue)Get a  Shortassociated with the given configuration key. | 
| Configuration | getSource(String key)Returns the configuration source, in which the specified key is defined. | 
| String | getString(String key)Get a string associated with the given configuration key. | 
| String | getString(String key,
         String defaultValue)Get a string associated with the given configuration key. | 
| String[] | getStringArray(String key)Get an array of strings associated with the given configuration key. | 
| Configuration | interpolatedConfiguration()Returns a configuration with the same content as this configuration, but
 with all variables replaced by their actual values. | 
| void | invalidate()Invalidates the current combined configuration. | 
| void | invalidateAll() | 
| boolean | isEmpty()Checks if this configuration is empty. | 
| boolean | removeConfiguration(Configuration config)Removes the specified configuration from this combined configuration. | 
| Configuration | removeConfiguration(String name)Removes the configuration with the specified name. | 
| Configuration | removeConfigurationAt(int index)Removes the configuration at the specified index. | 
| boolean | removeConfigurationListener(ConfigurationListener l)Removes the specified event listener so that it does not receive any
 further events caused by this object. | 
| boolean | removeErrorListener(ConfigurationErrorListener l)Removes the specified error listener so that it does not receive any
 further events caused by this object. | 
| protected Object | resolveContainerStore(String key)Returns an object from the store described by the key. | 
| void | setExpressionEngine(ExpressionEngine expressionEngine)Sets the expression engine to be used by this configuration. | 
| void | setKeyPattern(String pattern) | 
| void | setLoggerName(String name)Set the name of the Logger to use on each CombinedConfiguration. | 
| void | setNodeCombiner(NodeCombiner nodeCombiner)Sets the node combiner. | 
| void | setProperty(String key,
           Object value)Sets the value of the specified property. | 
| void | setRoot(HierarchicalConfiguration.Node node)Sets the root node of this hierarchical configuration. | 
| void | setRootNode(ConfigurationNode rootNode)Sets the root node of this hierarchical configuration. | 
| Configuration | subset(String prefix)Creates a new  Configurationobject containing all keys
 that start with the specified prefix. | 
addConfiguration, addConfiguration, configurationChanged, fetchNodeList, getConfigurationNameList, getConfigurations, getConversionExpressionEngine, isForceReloadCheck, isIgnoreReloadExceptions, performReloadCheck, setConversionExpressionEngine, setForceReloadCheck, setIgnoreReloadExceptionsgetReloadLockaddPropertyDirect, clearNode, clearNode, clearReferences, createAddPath, createNode, createSubnodeConfiguration, createSubnodeConfiguration, fetchAddNode, findLastPathNode, findPropertyNodes, getDefaultExpressionEngine, nodeDefined, nodeDefined, removeNode, removeNode, setDefaultExpressionEngine, subnodeConfigurationChangedaddErrorLogListener, append, clearPropertyDirect, copy, createInterpolator, getDefaultListDelimiter, getDelimiter, getInterpolator, getListDelimiter, getLogger, getProperties, getSubstitutor, interpolate, interpolate, interpolateHelper, isDelimiterParsingDisabled, isScalarValue, isThrowExceptionOnMissing, setDefaultListDelimiter, setDelimiter, setDelimiterParsingDisabled, setListDelimiter, setLogger, setThrowExceptionOnMissingcreateErrorEvent, createEvent, fireError, fireEvent, isDetailEvents, setDetailEventspublic DynamicCombinedConfiguration(NodeCombiner comb)
DynamicCombinedConfiguration and
 initializes the combiner to be used.comb - the node combiner (can be null, then a union combiner
 is used as default)public DynamicCombinedConfiguration()
DynamicCombinedConfiguration that uses
 a union combiner.UnionCombinerpublic void setKeyPattern(String pattern)
public String getKeyPattern()
public void setLoggerName(String name)
name - The Logger name.public NodeCombiner getNodeCombiner()
getNodeCombiner in class CombinedConfigurationpublic void setNodeCombiner(NodeCombiner nodeCombiner)
IllegalArgumentException exception is thrown. Changing the
 node combiner causes an invalidation of this combined configuration, so
 that the new combiner immediately takes effect.setNodeCombiner in class CombinedConfigurationnodeCombiner - the node combinerpublic void addConfiguration(AbstractConfiguration config, String name, String at)
ConfigurationRuntimeException will
 be thrown. With the optional at argument you can specify
 where in the resulting node structure the content of the added
 configuration should appear. This is a string that uses dots as property
 delimiters (independent on the current expression engine). For instance
 if you pass in the string "database.tables",
 all properties of the added configuration will occur in this branch.addConfiguration in class CombinedConfigurationconfig - the configuration to add (must not be null)name - the name of this configuration (can be null)at - the position of this configuration in the combined tree (can be
 null)public int getNumberOfConfigurations()
getNumberOfConfigurations in class CombinedConfigurationpublic Configuration getConfiguration(int index)
getConfiguration in class CombinedConfigurationindex - the indexpublic Configuration getConfiguration(String name)
getConfiguration in class CombinedConfigurationname - the name of the configurationpublic Set<String> getConfigurationNames()
getConfigurationNames in class CombinedConfigurationpublic Configuration removeConfiguration(String name)
removeConfiguration in class CombinedConfigurationname - the name of the configuration to be removedpublic boolean removeConfiguration(Configuration config)
removeConfiguration in class CombinedConfigurationconfig - the configuration to be removedpublic Configuration removeConfigurationAt(int index)
removeConfigurationAt in class CombinedConfigurationindex - the indexpublic ConfigurationNode getRootNode()
getRootNode in class CombinedConfigurationpublic void setRootNode(ConfigurationNode rootNode)
HierarchicalConfigurationsetRootNode in class HierarchicalConfigurationrootNode - the root nodepublic void addProperty(String key, Object value)
Configurationresource.loader = fileis already present in the configuration and you call
addProperty("resource.loader", "classpath")
 Then you will end up with a List like the following:
 ["file", "classpath"]
addProperty in interface ConfigurationaddProperty in class AbstractConfigurationkey - The key to add the property to.value - The value to add.public void clear()
CombinedConfigurationclear in interface Configurationclear in class CombinedConfigurationpublic void clearProperty(String key)
HierarchicalConfigurationclearProperty in interface ConfigurationclearProperty in class HierarchicalConfigurationkey - the key of the property to be removedpublic boolean containsKey(String key)
HierarchicalConfigurationcontainsKey in interface ConfigurationcontainsKey in class HierarchicalConfigurationkey - the key to be chekcedpublic BigDecimal getBigDecimal(String key, BigDecimal defaultValue)
ConfigurationBigDecimal associated with the given configuration key.
 If the key doesn't map to an existing object, the default value
 is returned.getBigDecimal in interface ConfigurationgetBigDecimal in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public BigDecimal getBigDecimal(String key)
AbstractConfigurationBigDecimal associated with the given configuration key.getBigDecimal in interface ConfigurationgetBigDecimal in class AbstractConfigurationkey - The configuration key.AbstractConfiguration.setThrowExceptionOnMissing(boolean)public BigInteger getBigInteger(String key, BigInteger defaultValue)
ConfigurationBigInteger associated with the given configuration key.
 If the key doesn't map to an existing object, the default value
 is returned.getBigInteger in interface ConfigurationgetBigInteger in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public BigInteger getBigInteger(String key)
AbstractConfigurationBigInteger associated with the given configuration key.getBigInteger in interface ConfigurationgetBigInteger in class AbstractConfigurationkey - The configuration key.AbstractConfiguration.setThrowExceptionOnMissing(boolean)public boolean getBoolean(String key, boolean defaultValue)
AbstractConfigurationgetBoolean in interface ConfigurationgetBoolean in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.PropertyConverter.toBoolean(Object)public Boolean getBoolean(String key, Boolean defaultValue)
AbstractConfigurationBoolean object. If the property has no value, the passed
 in default value will be used.getBoolean in interface ConfigurationgetBoolean in class AbstractConfigurationkey - the key of the propertydefaultValue - the default valueBooleanPropertyConverter.toBoolean(Object)public boolean getBoolean(String key)
AbstractConfigurationgetBoolean in interface ConfigurationgetBoolean in class AbstractConfigurationkey - The configuration key.PropertyConverter.toBoolean(Object)public byte getByte(String key, byte defaultValue)
ConfigurationgetByte in interface ConfigurationgetByte in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public Byte getByte(String key, Byte defaultValue)
ConfigurationByte associated with the given configuration key.getByte in interface ConfigurationgetByte in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public byte getByte(String key)
ConfigurationgetByte in interface ConfigurationgetByte in class AbstractConfigurationkey - The configuration key.public double getDouble(String key, double defaultValue)
ConfigurationgetDouble in interface ConfigurationgetDouble in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public Double getDouble(String key, Double defaultValue)
ConfigurationDouble associated with the given configuration key.getDouble in interface ConfigurationgetDouble in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public double getDouble(String key)
ConfigurationgetDouble in interface ConfigurationgetDouble in class AbstractConfigurationkey - The configuration key.public float getFloat(String key, float defaultValue)
ConfigurationgetFloat in interface ConfigurationgetFloat in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public Float getFloat(String key, Float defaultValue)
ConfigurationFloat associated with the given configuration key.
 If the key doesn't map to an existing object, the default value
 is returned.getFloat in interface ConfigurationgetFloat in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public float getFloat(String key)
ConfigurationgetFloat in interface ConfigurationgetFloat in class AbstractConfigurationkey - The configuration key.public int getInt(String key, int defaultValue)
ConfigurationgetInt in interface ConfigurationgetInt in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public int getInt(String key)
ConfigurationgetInt in interface ConfigurationgetInt in class AbstractConfigurationkey - The configuration key.public Integer getInteger(String key, Integer defaultValue)
ConfigurationInteger associated with the given configuration key.
 If the key doesn't map to an existing object, the default value
 is returned.getInteger in interface ConfigurationgetInteger in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public Iterator<String> getKeys()
HierarchicalConfigurationgetKeys in interface ConfigurationgetKeys in class HierarchicalConfigurationpublic Iterator<String> getKeys(String prefix)
HierarchicalConfigurationgetKeys in interface ConfigurationgetKeys in class HierarchicalConfigurationprefix - the prefix of the keys to start withConfiguration.getKeys()public List<Object> getList(String key, List<?> defaultValue)
ConfigurationgetList in interface ConfigurationgetList in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public List<Object> getList(String key)
AbstractConfigurationgetList in interface ConfigurationgetList in class AbstractConfigurationkey - The configuration key.AbstractConfiguration.getStringArray(String)public long getLong(String key, long defaultValue)
ConfigurationgetLong in interface ConfigurationgetLong in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public Long getLong(String key, Long defaultValue)
ConfigurationLong associated with the given configuration key.
 If the key doesn't map to an existing object, the default value
 is returned.getLong in interface ConfigurationgetLong in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public long getLong(String key)
ConfigurationgetLong in interface ConfigurationgetLong in class AbstractConfigurationkey - The configuration key.public Properties getProperties(String key)
ConfigurationProperties object, the value parts
 become values.getProperties in interface ConfigurationgetProperties in class AbstractConfigurationkey - The configuration key.public Object getProperty(String key)
HierarchicalConfigurationgetProperty in interface ConfigurationgetProperty in class HierarchicalConfigurationkey - the key to be looked uppublic short getShort(String key, short defaultValue)
ConfigurationgetShort in interface ConfigurationgetShort in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public Short getShort(String key, Short defaultValue)
ConfigurationShort associated with the given configuration key.
 If the key doesn't map to an existing object, the default value
 is returned.getShort in interface ConfigurationgetShort in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public short getShort(String key)
ConfigurationgetShort in interface ConfigurationgetShort in class AbstractConfigurationkey - The configuration key.public String getString(String key, String defaultValue)
ConfigurationgetString in interface ConfigurationgetString in class AbstractConfigurationkey - The configuration key.defaultValue - The default value.public String getString(String key)
AbstractConfigurationgetString in interface ConfigurationgetString in class AbstractConfigurationkey - The configuration key.AbstractConfiguration.setThrowExceptionOnMissing(boolean)public String[] getStringArray(String key)
AbstractConfigurationsetListDelimiter() method. If this is the case, the string
 is split at these positions resulting in a property with multiple
 values.getStringArray in interface ConfigurationgetStringArray in class AbstractConfigurationkey - The configuration key.AbstractConfiguration.setListDelimiter(char), 
AbstractConfiguration.setDelimiterParsingDisabled(boolean)public boolean isEmpty()
HierarchicalConfigurationisEmpty in interface ConfigurationisEmpty in class HierarchicalConfigurationpublic void setProperty(String key, Object value)
HierarchicalConfigurationsetProperty in interface ConfigurationsetProperty in class HierarchicalConfigurationkey - the key of the property to setvalue - the new value of this propertypublic Configuration subset(String prefix)
HierarchicalConfigurationConfiguration object containing all keys
 that start with the specified prefix. This implementation will return a
 HierarchicalConfiguration object so that the structure of
 the keys will be saved. The nodes selected by the prefix (it is possible
 that multiple nodes are selected) are mapped to the root node of the
 returned configuration, i.e. their children and attributes will become
 children and attributes of the new root node. However a value of the root
 node is only set if exactly one of the selected nodes contain a value (if
 multiple nodes have a value, there is simply no way to decide how these
 values are merged together). Note that the returned
 Configuration object is not connected to its source
 configuration: updates on the source configuration are not reflected in
 the subset and vice versa.subset in interface Configurationsubset in class HierarchicalConfigurationprefix - the prefix of the keys for the subsetSubsetConfigurationpublic HierarchicalConfiguration.Node getRoot()
HierarchicalConfigurationHierarchicalConfiguration.getRootNode() method instead, which operates on
 the preferred data type ConfigurationNode.getRoot in class HierarchicalConfigurationpublic void setRoot(HierarchicalConfiguration.Node node)
HierarchicalConfigurationHierarchicalConfiguration.setRootNode(ConfigurationNode) method instead,
 which operates on the preferred data type ConfigurationNode.setRoot in class HierarchicalConfigurationnode - the root nodepublic ExpressionEngine getExpressionEngine()
HierarchicalConfigurationgetExpressionEngine in class HierarchicalConfigurationpublic void setExpressionEngine(ExpressionEngine expressionEngine)
HierarchicalConfigurationsetExpressionEngine in class HierarchicalConfigurationexpressionEngine - the new expression engine; can be null,
 then the default expression engine will be usedpublic void addNodes(String key, Collection<? extends ConfigurationNode> nodes)
HierarchicalConfigurationaddProperty(), but
 instead of a single property a whole collection of nodes can be added -
 and thus complete configuration sub trees. E.g. with this method it is
 possible to add parts of another HierarchicalConfiguration
 object to this object. (However be aware that a
 ConfigurationNode object can only belong to a single
 configuration. So if nodes from one configuration are directly added to
 another one using this method, the structure of the source configuration
 will be broken. In this case you should clone the nodes to be added
 before calling addNodes().) If the passed in key refers to
 an existing and unique node, the new nodes are added to this node.
 Otherwise a new node will be created at the specified position in the
 hierarchy.addNodes in class HierarchicalConfigurationkey - the key where the nodes are to be added; can be null ,
 then they are added to the root nodenodes - a collection with the Node objects to be
 addedpublic SubnodeConfiguration configurationAt(String key, boolean supportUpdates)
HierarchicalConfiguration
 Returns a hierarchical subnode configuration object that wraps the
 configuration node specified by the given key. This method provides an
 easy means of accessing sub trees of a hierarchical configuration. In the
 returned configuration the sub tree can directly be accessed, it becomes
 the root node of this configuration. Because of this the passed in key
 must select exactly one configuration node; otherwise an
 IllegalArgumentException will be thrown.
 
 The difference between this method and the
 HierarchicalConfiguration.subset(String) method is that
 subset() supports arbitrary subsets of configuration nodes
 while configurationAt() only returns a single sub tree.
 Please refer to the documentation of the
 SubnodeConfiguration class to obtain further information
 about subnode configurations and when they should be used.
 
 With the supportUpdate flag the behavior of the returned
 SubnodeConfiguration regarding updates of its parent
 configuration can be determined. A subnode configuration operates on the
 same nodes as its parent, so changes at one configuration are normally
 directly visible for the other configuration. There are however changes
 of the parent configuration, which are not recognized by the subnode
 configuration per default. An example for this is a reload operation (for
 file-based configurations): Here the complete node set of the parent
 configuration is replaced, but the subnode configuration still references
 the old nodes. If such changes should be detected by the subnode
 configuration, the supportUpdates flag must be set to
 true. This causes the subnode configuration to reevaluate the key
 used for its creation each time it is accessed. This guarantees that the
 subnode configuration always stays in sync with its key, even if the
 parent configuration's data significantly changes. If such a change
 makes the key invalid - because it now no longer points to exactly one
 node -, the subnode configuration is not reconstructed, but keeps its
 old data. It is then quasi detached from its parent.
 
configurationAt in class HierarchicalConfigurationkey - the key that selects the sub treesupportUpdates - a flag whether the returned subnode configuration
 should be able to handle updates of its parentSubnodeConfigurationpublic SubnodeConfiguration configurationAt(String key)
HierarchicalConfigurationconfigurationAt(key,
 <b>false</b>).configurationAt in class HierarchicalConfigurationkey - the key that selects the sub treeSubnodeConfigurationpublic List<HierarchicalConfiguration> configurationsAt(String key)
HierarchicalConfigurationExpressionEngine) and then create a subnode
 configuration for each returned node (like
 HierarchicalConfiguration.configurationAt(String)}). This is especially
 useful when dealing with list-like structures. As an example consider the
 configuration that contains data about database tables and their fields.
 If you need access to all fields of a certain table, you can simply do
 
 List fields = config.configurationsAt("tables.table(0).fields.field");
 for(Iterator it = fields.iterator(); it.hasNext();)
 {
     HierarchicalConfiguration sub = (HierarchicalConfiguration) it.next();
     // now the children and attributes of the field node can be
     // directly accessed
     String fieldName = sub.getString("name");
     String fieldType = sub.getString("type");
     ...
 configurationsAt in class HierarchicalConfigurationkey - the key for selecting the desired nodespublic void clearTree(String key)
HierarchicalConfigurationclearTree("foo") would remove both properties.clearTree in class HierarchicalConfigurationkey - the key of the property to be removedpublic int getMaxIndex(String key)
HierarchicalConfigurationgetMaxIndex in class HierarchicalConfigurationkey - the key to be checkedpublic Configuration interpolatedConfiguration()
HierarchicalConfigurationinterpolatedConfiguration in class HierarchicalConfigurationpublic Configuration getSource(String key)
IllegalArgumentException is
 thrown (in this case no unique source can be determined).getSource in class CombinedConfigurationkey - the key of a configuration propertyIllegalArgumentException - if the key maps to multiple properties
 and the source cannot be determined, or if the key is nullpublic void addConfigurationListener(ConfigurationListener l)
EventSourceaddConfigurationListener in class EventSourcel - the listener to addpublic boolean removeConfigurationListener(ConfigurationListener l)
EventSourceremoveConfigurationListener in class EventSourcel - the listener to be removedpublic Collection<ConfigurationListener> getConfigurationListeners()
EventSourcegetConfigurationListeners in class EventSourceConfigurationListeners (this collection is a snapshot
 of the currently registered listeners; manipulating it has no effect
 on this event source object)public void clearConfigurationListeners()
EventSourceclearConfigurationListeners in class EventSourcepublic void addErrorListener(ConfigurationErrorListener l)
EventSourceaddErrorListener in class EventSourcel - the listener to register (must not be null)public boolean removeErrorListener(ConfigurationErrorListener l)
EventSourceremoveErrorListener in class EventSourcel - the listener to removepublic void clearErrorListeners()
EventSourceclearErrorListeners in class EventSourcepublic Collection<ConfigurationErrorListener> getErrorListeners()
EventSourcegetErrorListeners in class EventSourceConfigurationErrorListeners (this collection is a
 snapshot of the currently registered listeners; it cannot be manipulated)public Object clone()
clone in class CombinedConfigurationpublic void invalidate()
EVENT_COMBINED_INVALIDATE is fired. Note that while other
 events most times appear twice (once before and once after an update),
 this event is only fired once (after update).invalidate in class CombinedConfigurationpublic void invalidateAll()
protected Object resolveContainerStore(String key)
AbstractConfigurationresolveContainerStore in class AbstractConfigurationkey - The property key.Copyright © 2001–2013 The Apache Software Foundation. All rights reserved.