|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mule.transport.legstar.config.ConfigUtils
public final class ConfigUtils
Helper methods for configuration.
| Method Summary | |
|---|---|
static HostProgram |
getHostProgram(String propertyFileName)
A helper to create a hostProgram configuration from a properties file. |
static int |
getInt(Properties props,
String key)
Safe get for integers. |
static void |
loadContainer(Properties props,
List<HostContainer> containers,
String nameKey,
String lengthKey)
Create a map with container names and associated max size from entries in a property file. |
static Properties |
loadFromPropFile(String propFileName)
Loads a properties file from classpath into memory. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static Properties loadFromPropFile(String propFileName)
throws IOException
propFileName - the properties file name
IOException - if file cannot be loaded
public static int getInt(Properties props,
String key)
props - a properties setkey - the key to value
public static HostProgram getHostProgram(String propertyFileName)
throws IOException
propertyFileName - the property file name
IOException - if properties file cannot be read
public static void loadContainer(Properties props,
List<HostContainer> containers,
String nameKey,
String lengthKey)
props - program attributes as propertiescontainers - a list of containers to fillnameKey - the properties key for container namelengthKey - the properties key for container size
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||