org.apache.mina.transport.tcp

## Class AbstractTcpServer

- java.lang.Object
- - org.apache.mina.service.AbstractIoService
  - - org.apache.mina.service.server.AbstractIoServer
    - - org.apache.mina.transport.tcp.AbstractTcpServer

All Implemented Interfaces:
  IoServer, IoService

Direct Known Subclasses:
  NioTcpServer

    public abstract class AbstractTcpServer
    extends AbstractIoServer

Base class for TCP based Servers

Author:
  Apache MINA Project

### Nested Class Summary

### Nested classes/interfaces inherited from class org.apache.mina.service.AbstractIoService

`AbstractIoService.ServiceState`

### Field Summary

### Fields inherited from class org.apache.mina.service.AbstractIoService

`config, ioHandlerExecutor`

### Constructor Summary

Constructors
`protected` `AbstractTcpServer(IoHandlerExecutor eventExecutor)` Create an new AbsractTcpServer instance
`protected` `AbstractTcpServer(TcpSessionConfig config, IoHandlerExecutor eventExecutor)` Create an new AbsractTcpServer instance, with a specific configuration

### Method Summary

Methods
`TcpSessionConfig` `getSessionConfig()` Returns the default configuration of the new `IoSession`s created by this service.
`void` `setSessionConfig(TcpSessionConfig config)` Set the default configuration for created TCP sessions

### Methods inherited from class org.apache.mina.service.server.AbstractIoServer

`isReuseAddress, setReuseAddress, setSessionConfig`

### Methods inherited from class org.apache.mina.service.AbstractIoService

`fireServiceActivated, fireServiceInactivated, getFilters, getIoHandler, getIoHandlerExecutor, getManagedSessions, initState, isActive, isCreated, isDisposed, isDisposing, isSuspended, setActive, setCreated, setDisposed, setDisposing, setFilters, setIoHandler, setSuspended`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.apache.mina.api.IoServer

`bind, bind, getBoundAddress, unbind`

### Constructor Detail

#### AbstractTcpServer

    protected AbstractTcpServer(IoHandlerExecutor eventExecutor)

Create an new AbsractTcpServer instance

Parameters:
  `eventExecutor` - used for executing IoHandler event in another pool of thread (not in the low level I/O one). Use `null` if you don't want one. Be careful, the IoHandler processing will block the I/O operations.

#### AbstractTcpServer

    protected AbstractTcpServer(TcpSessionConfig config,
                     IoHandlerExecutor eventExecutor)

Create an new AbsractTcpServer instance, with a specific configuration

Parameters:
  `sessionConfig` - The configuration to use for this server
  `eventExecutor` - used for executing IoHandler event in another pool of thread (not in the low level I/O one). Use `null` if you don't want one. Be careful, the IoHandler processing will block the I/O operations.

### Method Detail

#### getSessionConfig

    public TcpSessionConfig getSessionConfig()

Returns the default configuration of the new `IoSession`s created by this service.

Specified by:
  `getSessionConfig` in interface `IoService`
Overrides:
  `getSessionConfig` in class `AbstractIoServer`
Returns:
  The default configuration for this `IoService`

#### setSessionConfig

    public void setSessionConfig(TcpSessionConfig config)

Set the default configuration for created TCP sessions

Parameters:
  `config` -