|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.jlf.config.AppConfigProperties
AppConfigProperties
is a concrete class which delivers
container-specific configuration information
about the Java Virtual Machine instance the application is running
under. This is the default configuration class, which tries to pick
up -D options on the java start command to locate the main application
property file and the application configuration directory. The rest of
the layered frameworks use this class to pick up configuration options
in property files, either the main property file (application configuration
directory + main application property file) or sub-property files
(application configuration directory plus sub-property file name).
The defaults for application configuration directory is the current directory (.), that is, the directory where you invoked the java start command, and the main application property file is App.properties in that directory. You can override either of these by something like:
java ... -Dorg.jlf.config.applicationConfigDir=/home/myApp -Dorg.jlf.config.applicationPropertyFile=MainApp.properties ...Implementation note: This class is generally not exposed outside the package, it is wrapped by the AppInfo class. This class should have concrete subclasses which are container-specific (for example,
WebLogicAppConfigProperties
).
AppInfo
Field Summary | |
static java.lang.String |
APPLICATION_CONFIGURATION_DIRECTORY_DEFAULT
The default value for the application configuration directory (the current directory where you started the JVM). |
static java.lang.String |
APPLICATION_CONFIGURATION_DIRECTORY_PROPERTY
The System property name (one of the -D options on the java command line start directive) which contains the directory location of property files used throughout the framework. |
static java.lang.String |
APPLICATION_PROPERTY_FILE_PROPERTY
The System property name (one of the -D options on the java command line start directive) which contains the location of the main property file. |
static java.lang.String |
DEFAULT_APPLICATION_NAME
|
static java.lang.String |
DEFAULT_APPLICATION_PROPERTY_FILE
The default property file name if none can be found by using the above setting. |
Constructor Summary | |
AppConfigProperties()
|
Method Summary | |
java.lang.String |
getApplicationConfigurationDirectory()
Retrieves the main application configuration directory. |
java.lang.String |
getApplicationName()
Retrieves the name for the application to uniquely identify it from other Java virtual machine instances running on the network. |
java.lang.String |
getApplicationPropertyFileName()
Retrieves the name of the main application property file |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String APPLICATION_PROPERTY_FILE_PROPERTY
public static final java.lang.String DEFAULT_APPLICATION_NAME
public static final java.lang.String DEFAULT_APPLICATION_PROPERTY_FILE
public static final java.lang.String APPLICATION_CONFIGURATION_DIRECTORY_PROPERTY
public static final java.lang.String APPLICATION_CONFIGURATION_DIRECTORY_DEFAULT
Constructor Detail |
public AppConfigProperties()
Method Detail |
public java.lang.String getApplicationConfigurationDirectory()
public java.lang.String getApplicationPropertyFileName()
public java.lang.String getApplicationName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |