|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.smartics.properties.spi.config.support.PropertiesHelper
public final class PropertiesHelper
Simple utilities class to help on dealing with properties.
Constructor Summary | |
---|---|
PropertiesHelper(ConfigurationKey<?> key) Default constructor. |
Method Summary | |
---|---|
Properties |
readProperties(ClassLoader classLoader, String resourceId) Reads the properties from the given class path location. |
Properties |
readProperties(String resourceId) Reads the properties from the thread context class path location. |
Properties |
readProperties(String resourceId, InputStream input) Reads the properties from the given stream. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PropertiesHelper(ConfigurationKey<?> key)
key
- the key to the configuration to load properties for.
Method Detail |
---|
public Properties readProperties(String resourceId)
resourceId
- the resource on the class path to read.
public Properties readProperties(ClassLoader classLoader, String resourceId)
classLoader
- the class loader to access the resource.
resourceId
- the resource on the class path to read.
public Properties readProperties(String resourceId, InputStream input)
Closes the stream after the properties are read.
resourceId
- the identifier of the stream. Used for error reporting.
input
- the stream to read from.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |