com.arjuna.common.util.propertyservice
Class PropertiesFactory

java.lang.Object
  extended by com.arjuna.common.util.propertyservice.PropertiesFactory

public class PropertiesFactory
extends java.lang.Object

This class loads properties according to the file location, substitution and override rules described in the docs.

Author:
Richard A. Begg (richard.begg@arjuna.com)

Constructor Summary
PropertiesFactory()
           
 
Method Summary
static java.util.Properties getDefaultProperties()
          Returns the systems default properties, as read from the configuration file.
static java.util.Properties getPropertiesFromFile(java.lang.String propertyFileName, java.lang.ClassLoader classLoader)
          Returns the config properties read from a specified location.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertiesFactory

public PropertiesFactory()
Method Detail

getDefaultProperties

public static java.util.Properties getDefaultProperties()
Returns the systems default properties, as read from the configuration file.

Returns:
the configuration Properties

getPropertiesFromFile

public static java.util.Properties getPropertiesFromFile(java.lang.String propertyFileName,
                                                         java.lang.ClassLoader classLoader)
Returns the config properties read from a specified location.

Parameters:
propertyFileName - the file name. If relative, this is located using the FileLocator algorithm.
Returns:
the Properties loaded from the specified source.