public class TcpServerSap
extends java.lang.Object
Constructor and Description |
---|
TcpServerSap(ServerEventListener serverEventListener)
Use this constructor to create a ServerSAP that listens on port 4059 using the default ServerSocketFactory.
|
Modifier and Type | Method and Description |
---|---|
int |
getMaxConnections() |
int |
getPort() |
javax.net.ServerSocketFactory |
getServerSocketFactory() |
int |
messageFragmentTimeout() |
void |
setMaxConnections(int maxConnections)
Set the maximum number of client connections that are allowed in parallel.
|
void |
startListening()
Starts a new thread that listens on the configured port.
|
public TcpServerSap(ServerEventListener serverEventListener)
serverEventListener
- the ServerConnectionListener that will be notified when remote clients are connecting or the server
stopped listening.public int messageFragmentTimeout()
public void setMaxConnections(int maxConnections)
maxConnections
- the number of connections allowed (default is 100)public int getMaxConnections()
public void startListening() throws java.io.IOException
java.io.IOException
- if any kind of error occures while creating the server socket.public int getPort()
public javax.net.ServerSocketFactory getServerSocketFactory()