public abstract class AbstractServer extends Service
Thread.State, Thread.UncaughtExceptionHandler| Modifier and Type | Field and Description |
|---|---|
protected InetAddress |
bindTo |
protected org.slf4j.Logger |
log |
protected Managers |
managers |
protected ServerSocket |
serverSocket |
protected ServerSetup |
setup |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY| Modifier | Constructor and Description |
|---|---|
protected |
AbstractServer(ServerSetup setup,
Managers managers) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract ProtocolHandler |
createProtocolHandler(Socket clientSocket)
Create a new, specific protocol handler such as for IMAP.
|
String |
getBindTo() |
int |
getPort() |
String |
getProtocol() |
ServerSetup |
getServerSetup() |
protected ServerSocket |
openServerSocket() |
void |
quit() |
void |
run() |
String |
toString() |
destroy, init, isRunning, keepOn, setRunning, startService, stopService, stopService, stopService, wait_for_runningactiveCount, 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, yieldprotected final org.slf4j.Logger log
protected final InetAddress bindTo
protected ServerSocket serverSocket
protected Managers managers
protected ServerSetup setup
protected AbstractServer(ServerSetup setup, Managers managers)
protected abstract ProtocolHandler createProtocolHandler(Socket clientSocket)
clientSocket - the client socket to use.protected ServerSocket openServerSocket() throws IOException
IOExceptionpublic String getBindTo()
public int getPort()
public String getProtocol()
public ServerSetup getServerSetup()
Copyright © 2006-2014 Icegreen Technologies. All Rights Reserved.