|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.wcb.autohome.util.HAConfigLoader
Project: Alice X10 Interface Filename: $Id: HAConfigLoader.java,v 1.11 2004/02/02 23:41:31 wbogaardt Exp $ Abstract: Server Config file loader
Field Summary | |
static java.lang.String |
sDEFAULT_FILENAME
|
static java.lang.String |
sFILE_HEADER
|
Constructor Summary | |
HAConfigLoader()
|
|
HAConfigLoader(java.lang.String fileName)
|
|
HAConfigLoader(java.lang.String fileName,
java.lang.String directory)
|
Method Summary | |
java.lang.Object |
getObject(java.lang.Object propName)
This returns the object, which is usually a string from the property file |
java.util.Properties |
getProperties()
Gets the properties from the file system and returns it as a properties hash. |
java.lang.String |
getProperty(java.lang.String propName)
Gets the value of a specified key name in the properties hash. |
boolean |
isEmpty(java.lang.String propName)
Returns true if the specified property is empty. |
java.util.Properties |
load(java.lang.String directory,
java.lang.String file)
Load the specified properties file. |
void |
saveProperties()
Saves the properties file to the file system. |
void |
setProperties(java.util.Properties newProp)
Sets the properties object to the passed in value. |
void |
setProperty(java.lang.String prop,
java.lang.Object value)
This returns an object, which is a string from the property file based on a string of the key name. |
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 sDEFAULT_FILENAME
public static final java.lang.String sFILE_HEADER
Constructor Detail |
public HAConfigLoader()
public HAConfigLoader(java.lang.String fileName)
public HAConfigLoader(java.lang.String fileName, java.lang.String directory)
Method Detail |
public java.util.Properties load(java.lang.String directory, java.lang.String file)
public java.util.Properties getProperties()
public boolean isEmpty(java.lang.String propName)
propName
- property key to check
public java.lang.String getProperty(java.lang.String propName)
propName
- key name
public java.lang.Object getObject(java.lang.Object propName)
propName
-
public void setProperty(java.lang.String prop, java.lang.Object value)
prop
- String representation of the key namevalue
- OBject, which is a string.public void setProperties(java.util.Properties newProp)
newProp
- New properties hash.public void saveProperties()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |