org.productivity.java.syslog4j.server.impl.net.tcp
Class TCPNetSyslogServer

java.lang.Object
  extended by org.productivity.java.syslog4j.server.impl.AbstractSyslogServer
      extended by org.productivity.java.syslog4j.server.impl.net.tcp.TCPNetSyslogServer
All Implemented Interfaces:
java.lang.Runnable, SyslogServerIF
Direct Known Subclasses:
SSLTCPNetSyslogServer

public class TCPNetSyslogServer
extends AbstractSyslogServer

TCPNetSyslogServer provides a simple threaded TCP/IP server implementation.

Syslog4j is licensed under the Lesser GNU Public License v2.1. A copy of the LGPL license is available in the META-INF folder in all distributions of Syslog4j and in the base directory of the "doc" ZIP.

Version:
$Id: TCPNetSyslogServer.java,v 1.23 2010/11/28 22:07:57 cvs Exp $
Author:
<syslog4j@productivity.org>

Nested Class Summary
static class TCPNetSyslogServer.TCPNetSyslogSocketHandler
           
 
Nested classes/interfaces inherited from class org.productivity.java.syslog4j.server.impl.AbstractSyslogServer
AbstractSyslogServer.Sessions
 
Field Summary
protected  java.net.ServerSocket serverSocket
           
protected  AbstractSyslogServer.Sessions sessions
           
protected  TCPNetSyslogServerConfigIF tcpNetSyslogServerConfig
           
 
Fields inherited from class org.productivity.java.syslog4j.server.impl.AbstractSyslogServer
shutdown, syslogProtocol, syslogServerConfig, thread
 
Constructor Summary
TCPNetSyslogServer()
           
 
Method Summary
protected  java.net.ServerSocket createServerSocket()
           
protected  javax.net.ServerSocketFactory getServerSocketFactory()
           
 AbstractSyslogServer.Sessions getSessions()
           
 void initialize()
           
 void run()
           
 void shutdown()
           
 
Methods inherited from class org.productivity.java.syslog4j.server.impl.AbstractSyslogServer
createEvent, createEvent, getConfig, getProtocol, getThread, handleDestroy, handleEvent, handleEvent, handleEvent, handleException, handleInitialize, handleSessionClosed, handleSessionOpen, initialize, isStructuredMessage, isStructuredMessage, setThread
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serverSocket

protected java.net.ServerSocket serverSocket

sessions

protected final AbstractSyslogServer.Sessions sessions

tcpNetSyslogServerConfig

protected TCPNetSyslogServerConfigIF tcpNetSyslogServerConfig
Constructor Detail

TCPNetSyslogServer

public TCPNetSyslogServer()
Method Detail

initialize

public void initialize()
                throws SyslogRuntimeException
Specified by:
initialize in class AbstractSyslogServer
Throws:
SyslogRuntimeException

getSessions

public AbstractSyslogServer.Sessions getSessions()

shutdown

public void shutdown()
Specified by:
shutdown in interface SyslogServerIF
Overrides:
shutdown in class AbstractSyslogServer

getServerSocketFactory

protected javax.net.ServerSocketFactory getServerSocketFactory()
                                                        throws java.io.IOException
Throws:
java.io.IOException

createServerSocket

protected java.net.ServerSocket createServerSocket()
                                            throws java.io.IOException
Throws:
java.io.IOException

run

public void run()