|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.metamatrix.toolbox.ui.widget.util.PropertyLoader
public class PropertyLoader
PropertyLoader is a class for loading and working with property files, especially those containing repeating branch structures.
Field Summary | |
---|---|
static java.lang.String |
PROPERTY_PREFIX
|
Constructor Summary | |
---|---|
PropertyLoader(java.util.Properties props)
Constructor - set the properties object that this object should operate on. |
|
PropertyLoader(java.lang.String propertiesFile)
Constructor - specify the file (with path) for this object to load. |
Method Summary | |
---|---|
java.util.Properties |
getProperties()
return a Properties object containing all property pairs loaded into this object. |
java.util.Properties |
getPropertiesBranch(java.lang.String prefix)
return a Properties object containing all property pairs beneath the specified prefix. |
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_PREFIX
Constructor Detail |
---|
public PropertyLoader(java.lang.String propertiesFile)
propertiesFile
- property file name. May be either in a jar or on the file system.
PropertyLoader attempts to find the file as a jar resource first, then on the file system.public PropertyLoader(java.util.Properties props)
props
- objectMethod Detail |
---|
public java.util.Properties getProperties() throws PropertyLoaderException
PropertyLoaderException
- if the specified file name for the properties could not be found.public java.util.Properties getPropertiesBranch(java.lang.String prefix) throws PropertyLoaderException
PropertyLoaderException
- if the specified file name for the properties could not be found.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |