|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfhm.edu.fem.util.properties.PropertyCache
public class PropertyCache
Class Description: This class read it's input from a given properties file and caches the data in a hash map.
Field Summary | |
---|---|
protected static boolean |
isLogging
|
protected java.util.LinkedHashMap<java.lang.String,java.util.Properties> |
propertyMap
|
protected static PropertyCache |
theInstance
|
Constructor Summary | |
---|---|
protected |
PropertyCache()
Construct a new property cache Protected to enforce singleton |
Method Summary | |
---|---|
static PropertyCache |
getInstance()
Retrieve the sole instance of this property cache |
static java.util.Properties |
getProperties(java.lang.String fileName)
Retrieve the properties for the given filename |
static java.lang.String |
getProperty(java.lang.String fileName,
java.lang.String key)
Get the string value from given key over all the cached key-value-pairs inside given file resource |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static boolean isLogging
protected java.util.LinkedHashMap<java.lang.String,java.util.Properties> propertyMap
protected static PropertyCache theInstance
Constructor Detail |
---|
protected PropertyCache()
Method Detail |
---|
public static PropertyCache getInstance()
public static java.util.Properties getProperties(java.lang.String fileName)
fileName,
- the filename pointing to the properties filepublic static final java.lang.String getProperty(java.lang.String fileName, java.lang.String key)
filename
- The properties file containing the propertykey
- The key of the property
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |