Jumpi v1.2.0

Class FileConfigurationLoader

All Implemented Interfaces:

public class FileConfigurationLoader
extends ConfigurationLoader

Loads property files from either filesystem or classpath, and allows replacement substitution of system property values with specially marked property values. Property values starting with $ are replaced with system properties named after the $.

Field Summary
static java.lang.String PROPERTY_FILE_DEFAULT_VALUE
          Default properties filename.
Fields inherited from class org.jumpi.impl.AbstractConfigurationLoader
Constructor Summary
Method Summary
protected  void loadPropertySet(java.lang.String propertySetName, java.util.Hashtable props, java.util.Hashtable parameters)
           Load properties from a file, either on the filesystem or on the classpath.
Methods inherited from class org.jumpi.impl.ConfigurationLoader
Methods inherited from class org.jumpi.impl.AbstractConfigurationLoader
getConfiguration, getJumpiClassname, replaceCustomProperties, replaceSystemProperties
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail


public static final java.lang.String PROPERTY_FILE_DEFAULT_VALUE
Default properties filename. Value: jumpi.properties.

See Also:
Constant Field Values
Constructor Detail


public FileConfigurationLoader()
Method Detail


protected void loadPropertySet(java.lang.String propertySetName,
                               java.util.Hashtable props,
                               java.util.Hashtable parameters)
                        throws java.lang.Exception

Load properties from a file, either on the filesystem or on the classpath. The filename is provided in the propertySetName, which when null, will force the default filename to be loaded. All system properties are added to the returned properties, replacing any properties of the same name already loaded.

If the file is not located relative to the current working directory if it is a relative filename, or at the absolute path if it is an absolute filename, then the file is looked for as a system resource on the classpath. If it still not found then an exception is thrown.

loadPropertySet in class ConfigurationLoader
propertySetName - filename or null to use default filename.
props - the container for the loaded properties.
parameters - customization properties.
java.lang.Exception - if the file is not found on classpath or filesystem.

Jumpi v1.2.0

Copyright 2003, Peter Jonathan Klauser.