public class TCPTransport extends SocketTransport implements ClientTransport
is, os, receiveBufferSize, sendBufferSize, socket
Constructor and Description |
---|
TCPTransport()
Creates transport.
|
TCPTransport(String host,
int port)
Creates transport.
|
TCPTransport(String host,
int port,
boolean enableTcpNoDelay)
Creates transport.
|
TCPTransport(String host,
int port,
boolean enableTcpNoDelay,
int sendBufferSize,
int receiveBufferSize)
Creates transport.
|
Modifier and Type | Method and Description |
---|---|
String |
getAddress()
Getter for address value.
|
int |
getPort()
Getter for port value.
|
void |
open()
Open the transport.
|
void |
setAddress(String host)
Setter for address.
|
void |
setPort(int port)
Setter for port.
|
void |
setSocketFactory(SocketFactory socketFactory)
Setter for socket factory transport.
|
close, getInetAddress, getInputStream, getLocalPort, getOutputStream, getSSLCertificates, getSSLCipherSuite, getSSLProtocol, isBlockingSocket, isOpen, read, read, read, read, waitUntilReadyToWrite, write, write, write, write
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
read, read, write, write
close, getInetAddress, getLocalPort, getSSLCertificates, getSSLCipherSuite, getSSLProtocol, isBlockingSocket, isOpen, read, read, waitUntilReadyToWrite, write, write
public TCPTransport()
public TCPTransport(String host, int port)
host
- the transport hostport
- the transport portpublic TCPTransport(String host, int port, boolean enableTcpNoDelay)
host
- the transport hostport
- the transpot portenableTcpNoDelay
- enable/disable nagle sockets algorithmpublic TCPTransport(String host, int port, boolean enableTcpNoDelay, int sendBufferSize, int receiveBufferSize)
host
- the transport hostport
- the transpot portenableTcpNoDelay
- enable/disable nagle sockets algorithmsendBufferSize
- send buffer sizereceiveBufferSize
- receive buffer sizepublic void setSocketFactory(SocketFactory socketFactory)
setSocketFactory
in interface ClientTransport
socketFactory
- the socket factorypublic void setAddress(String host)
ClientTransport
setAddress
in interface ClientTransport
ClientTransport.setAddress(String)
public void setPort(int port)
ClientTransport
setPort
in interface ClientTransport
ClientTransport.setPort(int)
public String getAddress()
Transport
getAddress
in interface Transport
getAddress
in class SocketTransport
SocketTransport.getAddress()
public int getPort()
Transport
getPort
in interface Transport
getPort
in class SocketTransport
SocketTransport.getPort()
public void open() throws IOException
Transport
open
in interface Transport
open
in class SocketTransport
IOException
- - throws if error occurredTransport.open()
Copyright © 2000–2022 EPAM Systems. All rights reserved.