Package org.apache.commons.configuration2.builder

# Class HierarchicalBuilderParametersImpl

java.lang.Object
org.apache.commons.configuration2.builder.BasicBuilderParameters
org.apache.commons.configuration2.builder.FileBasedBuilderParametersImpl
org.apache.commons.configuration2.builder.HierarchicalBuilderParametersImpl

All Implemented Interfaces:
  `Cloneable`, `BasicBuilderProperties<BasicBuilderParameters>`, `BuilderParameters`, `FileBasedBuilderProperties<FileBasedBuilderParametersImpl>`, `HierarchicalBuilderProperties<HierarchicalBuilderParametersImpl>`

Direct Known Subclasses:
  `INIBuilderParametersImpl`, `XMLBuilderParametersImpl`

public class HierarchicalBuilderParametersImpl extends FileBasedBuilderParametersImpl implements HierarchicalBuilderProperties<HierarchicalBuilderParametersImpl>
A specialized parameters object for hierarchical configurations.

This class defines special properties for hierarchical configurations. Because most hierarchical configurations are file-based configurations this class extends `FileBasedBuilderParametersImpl`.

Since:
  2.0

- ## Field Summary

  ### Fields inherited from interface org.apache.commons.configuration2.builder.BuilderParameters

  `RESERVED_PARAMETER_PREFIX`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `HierarchicalBuilderParametersImpl()`
  Constructs a new instance.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `inheritFrom(Map<String,?> source)`
  Inherits properties from the specified map.
  `HierarchicalBuilderParametersImpl`
  `setExpressionEngine(ExpressionEngine engine)`
  Sets the `ExpressionEngine` to be used when querying the configuration.

  ### Methods inherited from class org.apache.commons.configuration2.builder.FileBasedBuilderParametersImpl

  `clone, fromMap, fromParameters, fromParameters, getFileHandler, getParameters, getReloadingDetectorFactory, getReloadingRefreshDelay, setBasePath, setEncoding, setFile, setFileName, setFileSystem, setLocationStrategy, setPath, setReloadingDetectorFactory, setReloadingRefreshDelay, setURL, setURL`

  ### Methods inherited from class org.apache.commons.configuration2.builder.BasicBuilderParameters

  `copyPropertiesFrom, fetchBeanHelper, fetchInterpolatorSpecification, fetchProperty, merge, setBeanHelper, setConfigurationDecoder, setConversionHandler, setDefaultLookups, setInterpolator, setListDelimiterHandler, setLogger, setParentInterpolator, setPrefixLookups, setSynchronizer, setThrowExceptionOnMissing, storeProperty`

  ### Methods inherited from class java.lang.Object

  `equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### HierarchicalBuilderParametersImpl

    public HierarchicalBuilderParametersImpl()
    Constructs a new instance.

- ## Method Details

  - ### inheritFrom

    public void inheritFrom(Map<String,?> source)
    Inherits properties from the specified map. This can be used for instance to reuse parameters from one builder in another builder - also in parent-child relations in which a parent builder creates child builders. The purpose of this method is to let a concrete implementation decide which properties can be inherited. Because parameters are basically organized as a map it would be possible to simply copy over all properties from the source object. However, this is not appropriate in all cases. For instance, some properties - like a `ConfigurationInterpolator` - are tightly connected to a configuration and cannot be reused in a different context. For other properties, for example a file name, it does not make sense to copy it. Therefore, an implementation has to be explicit in the properties it wants to take over. This implementation takes some properties defined in this class into account. This implementation copies some more properties defined by this class.
    Overrides:
      `inheritFrom` in class `FileBasedBuilderParametersImpl`
    Parameters:
      `source` - the source properties to inherit from

  - ### setExpressionEngine

    public HierarchicalBuilderParametersImpl setExpressionEngine(ExpressionEngine engine)
    Sets the `ExpressionEngine` to be used when querying the configuration. This implementation stores the expression engine in the internal parameters map.
    Specified by:
      `setExpressionEngine` in interface `HierarchicalBuilderProperties<HierarchicalBuilderParametersImpl>`
    Parameters:
      `engine` - the `ExpressionEngine`
    Returns:
      a reference to this object for method chaining