|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.figure8.join.core.setup.ApplicationConfig
public class ApplicationConfig
This ia an object that manages Join application configuration and associated
operations (such as loading or savind configuration). It uses backed
ConfigProperty
Java Beans for storing config informations.
Field Summary | |
---|---|
static java.lang.String |
CONFIG_FILE
Configuration file into Join Home directory. |
static java.lang.String |
CUSTOM_TYPE
Custom setup type property value |
static java.lang.String |
DISSOCIATED
Property used for telling that synch/asynch services are dissociated |
protected static org.apache.commons.logging.Log |
log
Get a commons logger. |
static java.lang.String |
OTHER_SIDE_URL
Property used for representing the url of this other side of application (if app is dissociated) |
static java.lang.String |
SETUP_COMPLETE
Property used for identifying the setup process has completed |
static java.lang.String |
SETUP_TYPE
Application properties determining setup type |
static java.lang.String |
STANDARD_TYPE
Standard setup type property value |
static java.lang.String |
SYNCH_SIDE
Property used for telling if this side of app is the synch side |
Constructor Summary | |
---|---|
ApplicationConfig()
Creates a new instance of ApplicationConfig |
Method Summary | |
---|---|
void |
addConfigProperty(ConfigProperty property)
Add a ConfigProperty obtained from configuration file |
boolean |
configurationFileExists()
Tells if configuration file is an existing file |
java.lang.String |
getApplicationHome()
|
static java.lang.String |
getConfigurationFileName()
Get the configuration file name into application home directory |
java.util.Properties |
getProperties()
|
java.lang.String |
getProperty(java.lang.String key)
Get a specific application config property |
boolean |
isAsynchronousSide()
|
boolean |
isCustomSetup()
|
boolean |
isDissociatedSetup()
|
boolean |
isSetupComplete()
|
boolean |
isStandardSetup()
|
boolean |
isSynchronousSide()
|
void |
load()
Load the application configuration from config file |
void |
save()
Save the application configuration to config file |
void |
setApplicationHome(java.lang.String home)
|
void |
setProperties(java.util.Properties props)
Set some application config properties. |
void |
setProperty(java.lang.String key,
java.lang.Object value)
Set an application config property. |
void |
setSetupComplete(boolean complete)
Set the flag telling if setup has been completed |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static org.apache.commons.logging.Log log
public static final java.lang.String CONFIG_FILE
public static final java.lang.String SETUP_TYPE
public static final java.lang.String CUSTOM_TYPE
public static final java.lang.String STANDARD_TYPE
public static final java.lang.String SYNCH_SIDE
public static final java.lang.String DISSOCIATED
public static final java.lang.String OTHER_SIDE_URL
public static final java.lang.String SETUP_COMPLETE
Constructor Detail |
---|
public ApplicationConfig()
Method Detail |
---|
public void setApplicationHome(java.lang.String home)
home
- Set the application home directorypublic java.lang.String getApplicationHome()
public void setProperties(java.util.Properties props)
props
- Properties to add to application props.public java.util.Properties getProperties()
public void setProperty(java.lang.String key, java.lang.Object value)
key
- Unique id of the application propertyvalue
- Value associated to keypublic java.lang.String getProperty(java.lang.String key)
key
- Unique id of the property to retrieve
public boolean isSetupComplete()
public void setSetupComplete(boolean complete)
complete
- Setup completion statuspublic boolean isCustomSetup()
public boolean isStandardSetup()
public boolean isSynchronousSide()
public boolean isAsynchronousSide()
public boolean isDissociatedSetup()
public boolean configurationFileExists()
public void addConfigProperty(ConfigProperty property)
ConfigProperty
obtained from configuration file
property
- Property wrapper to addpublic void load() throws BootstrapException
BootstrapException
- if something wrong happens during file loadingpublic void save() throws java.io.IOException
java.io.IOException
- if something wrong occurs during file writingpublic static java.lang.String getConfigurationFileName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |