|
Arch4J 1.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.arch4j.util.StartupProvider
This class is the main service provider for startup services.
The services are accessed via the static getProvider()
method. This class is used to programmatically set additional
System properties as if they had been entered as -D paramters
on the VM command line. These are the set of properties that need
to be available to initialize property management.
This is especially useful for web applications or EJB services living within an application server container. It is undesirable to set VM parameters for the application server only to be used by the application. Therefore, a servlet can be initialized with properties and loaded when the web application container is started. It then uses this class to store the properties in the System which makes them available to refresh the property provider as if it had been initially configured from the command line parameters.
Method Summary | |
static StartupProvider |
getProvider()
Returns the single instance of the StartupProvider. |
void |
refresh()
Triggers a refresh of the property framework. |
static void |
resetProvider()
Reset the single instance of the StartupProvider. |
void |
setProperties(Properties properties)
Adds the given set of properties to the System ,
as if they had been entered on the VM command line with the -D parameter. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static StartupProvider getProvider()
public static void resetProvider()
public void setProperties(Properties properties)
System
,
as if they had been entered on the VM command line with the -D parameter.
This method also triggers a refresh of the property framework.
properties
- The additional properties to store.public void refresh()
|
Arch4J 1.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |