|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectbexee.util.BexeeProperties
Provides a convenient way for accessing system properties and bexee
properties of which the latter are stored in a file called
bexee.properties and must be somewhere in the classpath.
Note that system properties take precedence over all other properties unless a property is explicitly programmaticly set.
The system properties are always checked for changes whereas the properties
from the bexee.properties are only read once upon creation.
The class provides a number of static methods that always check first if the properties had been loaded from the properties file.
| Field Summary | |
protected static java.util.Properties |
bexee
|
protected static java.lang.String |
FILE_NAME
|
protected static java.util.Properties |
props
|
| Constructor Summary | |
BexeeProperties()
|
|
| Method Summary | |
static java.util.Properties |
getProperties()
Returns the initialized underlying property file. |
static java.lang.String |
getProperty(java.lang.String key)
Searches for the property with the specified key in this property list. |
static java.lang.String |
getProperty(java.lang.String key,
java.lang.String defaultValue)
Searches for the property with the specified key in this property list. |
static java.lang.Object |
setProperty(java.lang.String key,
java.lang.String value)
Calls the Hashtable method put. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected static final java.lang.String FILE_NAME
protected static java.util.Properties props
protected static java.util.Properties bexee
| Constructor Detail |
public BexeeProperties()
| Method Detail |
public static java.lang.String getProperty(java.lang.String key)
key - the property key.
public static java.lang.String getProperty(java.lang.String key,
java.lang.String defaultValue)
key - the hashtable keydefaultValue - a default value
public static java.util.Properties getProperties()
Property object.
public static java.lang.Object setProperty(java.lang.String key,
java.lang.String value)
key - the key to be placed into this property listvalue - the value corresponding to key
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||