public abstract class AbstractDaemon extends Object
Modifier and Type | Field and Description |
---|---|
protected static String |
CONFIGURATION_FILE |
protected static int |
EXIT_CANNOT_LOAD_RUNTIME_PROPERTIES |
protected static int |
EXIT_CANNOT_OPEN_MANAGEMENT_SERVER |
protected static int |
EXIT_CANNOT_SAVE_RUNTIME_PROPERTIES |
protected static int |
EXIT_CODE_ALREADY_STARTED |
protected static int |
EXIT_CODE_NOT_RUNNING |
protected static int |
EXIT_CODE_NOT_STARTED |
protected static int |
EXIT_CODE_OK |
Constructor and Description |
---|
AbstractDaemon() |
Modifier and Type | Method and Description |
---|---|
protected static void |
doRestart()
Do restart.
|
protected static void |
doShutdown()
Do shutdown.
|
protected static void |
doShutdown(org.refcodes.daemon.AbstractDaemon.ShutDownMode aShutDowenMode)
Do shutdown.
|
protected static void |
doStartup()
Do startup.
|
protected static void |
doStartup(String aConfigFileName)
Do startup.
|
protected static org.refcodes.configuration.Properties |
toConfigurationProperties(String aConfigFileName)
To configuration properties.
|
protected static File |
toRuntimePropertiesFile()
To runtime properties file.
|
protected static final String CONFIGURATION_FILE
protected static final int EXIT_CODE_OK
protected static final int EXIT_CODE_ALREADY_STARTED
protected static final int EXIT_CODE_NOT_RUNNING
protected static final int EXIT_CANNOT_OPEN_MANAGEMENT_SERVER
protected static final int EXIT_CANNOT_SAVE_RUNTIME_PROPERTIES
protected static final int EXIT_CANNOT_LOAD_RUNTIME_PROPERTIES
protected static final int EXIT_CODE_NOT_STARTED
protected static void doRestart()
protected static void doStartup()
protected static void doStartup(String aConfigFileName)
aConfigFileName
- the a config file nameprotected static void doShutdown()
protected static void doShutdown(org.refcodes.daemon.AbstractDaemon.ShutDownMode aShutDowenMode)
aShutDowenMode
- the a shut dowen modeprotected static File toRuntimePropertiesFile()
protected static org.refcodes.configuration.Properties toConfigurationProperties(String aConfigFileName) throws IOException, ParseException
aConfigFileName
- the a config file nameIOException
- thrown in case accessing or processing the properties
file failed.ParseException
- Signals that an error has been reached
unexpectedly while parsing the data to be loaded.Copyright © 2018. All rights reserved.