Class QExec
java.lang.Object
org.jpos.q2.QBeanSupport
org.jpos.q2.qbean.QExec
- All Implemented Interfaces:
Configurable, QBean, QExecMBean, QBeanSupportMBean, QPersist
QBean for starting and stopping scripts or programs.
Example xml: <exec class="org.jpos.q2.qbean.QExec"> <attr name="startScript">YOUR PATH TO PROGRAM</attr> <attr name="shutdownScript">YOUR PATH TO PROGRAM</attr> </exec>
-
Field Summary
Fields inherited from class QBeanSupport
cfg, log, scheduledThreadPoolExecutor -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionparseCommandLine(String commandLine) voidsetShutdownScript(String scriptPath) voidsetStartScript(String scriptPath) protected voidprotected voidMethods inherited from class QBeanSupport
addAttr, close, createElement, destroy, destroyService, getAttrs, getAttrs, getConfiguration, getDump, getFactory, getLoader, getLoaderURLS, getLog, getLogger, getName, getPersist, getProperties, getProperty, getRealm, getScheduledThreadPoolExecutor, getServer, getState, getStateAsString, init, initService, isModified, running, setAttr, setConfiguration, setLogger, setModified, setName, setPersist, setProperty, setRealm, setServer, setState, start, stopMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface QBeanSupportMBean
getDump, getLoader, getLoaderURLS, getLogger, getName, getRealm, getServer, setLogger, setName, setPersist, setRealm, setServerMethods inherited from interface QPersist
getPersist, isModified
-
Constructor Details
-
QExec
public QExec()
-
-
Method Details
-
startService
- Overrides:
startServicein classQBeanSupport- Throws:
Exception
-
stopService
- Overrides:
stopServicein classQBeanSupport- Throws:
Exception
-
setStartScript
- Specified by:
setStartScriptin interfaceQExecMBean
-
getStartScript
- Specified by:
getStartScriptin interfaceQExecMBean
-
setShutdownScript
- Specified by:
setShutdownScriptin interfaceQExecMBean
-
getShutdownScript
- Specified by:
getShutdownScriptin interfaceQExecMBean
-
parseCommandLine
-