org.pentaho.reporting.libraries.base.config

Class PropertyFileConfiguration

public class PropertyFileConfiguration extends HierarchicalConfiguration

A report configuration that reads its values from an arbitary property file.

Author: Thomas Morgner

Constructor Summary
PropertyFileConfiguration()
Default constructor.
Method Summary
voidload(String resourceName)
Lods the property file from a classpath resource name.
voidload(String resourceName, Class resourceSource)
Loads the properties stored in the given file.
voidload(InputStream in)
Loads the properties stored in the given file.

Constructor Detail

PropertyFileConfiguration

public PropertyFileConfiguration()
Default constructor.

Method Detail

load

public void load(String resourceName)
Lods the property file from a classpath resource name. The classpath resource must be loadable via PropertyFileConfiguration.class.getResource(..)

Parameters: resourceName the resource name to be loaded.

load

public void load(String resourceName, Class resourceSource)
Loads the properties stored in the given file. This method does nothing if the file does not exist or is unreadable. Appends the contents of the loaded properties to the already stored contents.

Parameters: resourceName the file name of the stored properties. resourceSource the class to which relative resource paths are resolved.

load

public void load(InputStream in)
Loads the properties stored in the given file. This method does nothing if the file does not exist or is unreadable. Appends the contents of the loaded properties to the already stored contents.

Parameters: in the input stream used to read the properties.