java.lang.Object
java.lang.Thread
ch.qos.logback.classic.net.SimpleSocketServer
- All Implemented Interfaces:
Runnable
- Direct Known Subclasses:
SimpleSSLSocketServer
A simple
SocketNode based server.
<b>Usage:</b> java ch.qos.logback.classic.net.SimpleSocketServer port configFile
where port is a port number where the server listens and
configFile is an XML configuration file fed to
JoranConfigurator.
- Since:
- 0.8.4
- Author:
- Ceki Gülcü, Sébastien Pennec
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler -
Field Summary
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()static voidconfigureLC(LoggerContext lc, String configFile) protected static voiddoMain(Class<? extends SimpleSocketServer> serverClass, String[] argv) protected StringgetClientThreadName(Socket socket) Returns a name to identify each client thread.getLatch()Used for testing purposesprotected ServerSocketFactoryGets the platform defaultServerSocketFactory.protected StringReturns the name given to the server thread.booleanisClosed()static voidvoidrun()voidMethods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
-
Constructor Details
-
SimpleSocketServer
-
-
Method Details
-
main
-
doMain
-
run
-
getServerThreadName
Returns the name given to the server thread. -
getClientThreadName
Returns a name to identify each client thread. -
getServerSocketFactory
Gets the platform defaultServerSocketFactory.Subclasses may override to provide a custom server socket factory.
-
getLatch
Used for testing purposes -
isClosed
-
close
-
socketNodeClosing
-
configureLC
- Throws:
JoranException
-