public class DefaultServerRun extends Thread
Thread.State, Thread.UncaughtExceptionHandler
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
Constructor and Description |
---|
DefaultServerRun(String[] theArgs) |
Modifier and Type | Method and Description |
---|---|
protected void |
doRun()
Parse and process the command line to start/stop the server.
|
protected void |
doStartServer(String[] theArgs)
Starts the server (in a blocking mode) and set up a socket listener.
|
protected void |
doStopServer(String[] theArgs)
Stops the server by connecting to the socket set up when the server
was started.
|
void |
run()
Sets up a listener socket and wait until we receive a request on it to
stop the running server.
|
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
public DefaultServerRun(String[] theArgs)
theArgs
- the command line argumentsprotected void doStartServer(String[] theArgs) throws Exception
theArgs
- the command line argumentsException
- if any error happens when starting the serverprotected void doStopServer(String[] theArgs) throws Exception
theArgs
- the command line argumentsException
- if any error happens when stopping the serverprotected final void doRun()
Copyright © 2004-2013 Codehaus. All Rights Reserved.