当前页面:
在线文档首页 >
JBoss 4.0.1 sp1 varia API Documentation 英文版文档
ChildProcessService (Various API) - JBoss 4.0.1 sp1 varia API Documentation 英文版文档
org.jboss.varia.process
Class ChildProcessService
java.lang.Object
org.jboss.mx.util.JBossNotificationBroadcasterSupport
org.jboss.system.ServiceMBeanSupport
org.jboss.varia.process.ChildProcessService
- All Implemented Interfaces:
- ChildProcessServiceMBean, javax.management.MBeanRegistration, javax.management.NotificationBroadcaster, javax.management.NotificationEmitter, org.jboss.system.Service, org.jboss.system.ServiceMBean
- public class ChildProcessService
- extends org.jboss.system.ServiceMBeanSupport
- implements ChildProcessServiceMBean
A service to manage a child process.
- Version:
- $Revision: 1.2 $
- Author:
- Jason Dillon
Fields inherited from class org.jboss.system.ServiceMBeanSupport |
log, server, SERVICE_CONTROLLER_SIG, serviceName |
Fields inherited from interface org.jboss.system.ServiceMBean |
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED |
Methods inherited from class org.jboss.system.ServiceMBeanSupport |
create, createService, destroy, destroyService, getLog, getName, getNextNotificationSequenceNumber, getObjectName, getServer, getServiceName, getState, getStateString, jbossInternalCreate, jbossInternalDescription, jbossInternalDestroy, jbossInternalLifecycle, jbossInternalStart, jbossInternalStop, postDeregister, postRegister, preDeregister, preRegister, start, stop |
Methods inherited from class org.jboss.mx.util.JBossNotificationBroadcasterSupport |
addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener, sendNotification |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.jboss.system.ServiceMBean |
getName, getState, getStateString, jbossInternalLifecycle |
Methods inherited from interface org.jboss.system.Service |
create, destroy, start, stop |
commandLine
protected String commandLine
- The command line of the process to execute.
env
protected Properties env
- The environment for the process.
workingDir
protected File workingDir
- The working directory of the process.
childProcess
protected Process childProcess
- The child, we are so proud.
loggerAdapterName
protected String loggerAdapterName
- The name of the logger adapter for the child process' streams.
inputAdapter
protected ChildProcessService.ReaderLoggerAdapter inputAdapter
- The input adapter, which takes the process' STDOUT and
turns them into logger calls.
errorAdapter
protected ChildProcessService.ReaderLoggerAdapter errorAdapter
- The input adapter, which takes the process' STDERR and
turns them into logger calls.
ChildProcessService
public ChildProcessService()
setCommandLine
public void setCommandLine(String commandLine)
- Specified by:
setCommandLine
in interface ChildProcessServiceMBean
getCommandLine
public String getCommandLine()
- Specified by:
getCommandLine
in interface ChildProcessServiceMBean
setEnvironment
public void setEnvironment(Properties env)
- Specified by:
setEnvironment
in interface ChildProcessServiceMBean
getEnvironment
public Properties getEnvironment()
- Specified by:
getEnvironment
in interface ChildProcessServiceMBean
setWorkingDirectory
public void setWorkingDirectory(File dir)
- Specified by:
setWorkingDirectory
in interface ChildProcessServiceMBean
getWorkingDirectory
public File getWorkingDirectory()
- Specified by:
getWorkingDirectory
in interface ChildProcessServiceMBean
getExitValue
public Integer getExitValue()
- Specified by:
getExitValue
in interface ChildProcessServiceMBean
setLoggerAdapterName
public void setLoggerAdapterName(String name)
- Specified by:
setLoggerAdapterName
in interface ChildProcessServiceMBean
getLoggerAdapterName
public String getLoggerAdapterName()
- Specified by:
getLoggerAdapterName
in interface ChildProcessServiceMBean
makeEnvArray
protected String[] makeEnvArray(Properties props)
startService
protected void startService()
throws Exception
- Throws:
Exception
stopService
protected void stopService()
throws Exception
- Throws:
Exception
Copyright © 2002 JBoss Group, LLC. All Rights Reserved.