|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.commons.discovery.tools.PropertiesHolder
public class PropertiesHolder
Holder for a default class. Class may be specified by name (String) or class (Class). Using the holder complicates the users job, but minimized # of API's.
| Constructor Summary | |
|---|---|
PropertiesHolder(Properties properties)
Creates a new PropertiesHolder instance given an
already load Properties set. |
|
PropertiesHolder(String propertiesFileName)
Creates a new PropertiesHolder instance given a
property file name. |
|
| Method Summary | |
|---|---|
Properties |
getProperties(SPInterface<?> spi,
ClassLoaders loaders)
Returns the Properties instance, loaded if necessary from propertiesFileName. |
String |
getPropertiesFileName()
Returns the property file name |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PropertiesHolder(Properties properties)
PropertiesHolder instance given an
already load Properties set.
properties - The already load Properties setpublic PropertiesHolder(String propertiesFileName)
PropertiesHolder instance given a
property file name.
propertiesFileName - The property file name| Method Detail |
|---|
public Properties getProperties(SPInterface<?> spi,
ClassLoaders loaders)
Properties instance, loaded if necessary from propertiesFileName.
spi - Optional SPI (may be null).
If provided, an attempt is made to load the
property file as-per Class.getResource().loaders - Used only if properties need to be loaded.
Properties, loaded if necessary.public String getPropertiesFileName()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||