|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfr.imag.adele.bundle.util.config.Configuration
configuration utility
Constructor Summary | |
Configuration()
|
Method Summary | |
static Hashtable |
getHashtable(Properties props,
String keyListPropertyName)
builds a hashtable from properties. the key list is in the property keyListPropertyName Example getHashtable(props,"keylist") returns a hashtable with 3 key-value entry keylist=bar;bubba;foo bar=BAR foo=1.5;float bubba=100;int |
static Map |
getMap(Properties props,
String keyListPropertyName)
builds a map from properties. the key list is in the property keyListPropertyName Example getMap(props,"keylist") returns a hashtable with 3 key-value entry keylist=bar;bubba;foo bar=BAR foo=1.5;float bubba=100;int |
static Vector |
getVector(Properties props,
String vectorPropertyName)
builds a (ordered) vector from properties. the index list is in the property keyListPropertyName Example getVector(props,"tab") returns a 4 elements vector (tab.5 is ignored since tab.4 does not exist) tab.0=bar tab.1=foo tab.2=1.5;float tab.3=100;int tab.5=10000;long |
static Properties |
loadProperties(InputStream in)
loads properties from a input stream |
static Properties |
loadProperties(String filename)
loads properties from a file |
static void |
printProperties(PrintStream ps,
Properties prop)
print properties in a printwriter |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Configuration()
Method Detail |
public static Properties loadProperties(String filename)
filename
- the properties file name
public static void printProperties(PrintStream ps, Properties prop)
prop
- the properties to printpublic static Properties loadProperties(InputStream in)
in
- the imput stream
public static Map getMap(Properties props, String keyListPropertyName)
keylist=bar;bubba;foo bar=BAR foo=1.5;float bubba=100;int
props
- the propertieskeyListPropertyName
- the property name of the key list (separed by ;)
public static Hashtable getHashtable(Properties props, String keyListPropertyName)
keylist=bar;bubba;foo bar=BAR foo=1.5;float bubba=100;int
props
- the propertieskeyListPropertyName
- the property name of the key list (separed by ;)
public static Vector getVector(Properties props, String vectorPropertyName)
tab.0=bar tab.1=foo tab.2=1.5;float tab.3=100;int tab.5=10000;long
props
- the propertiesvectorPropertyName
- the property name of the key list (separed by ;)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |