public class TcpClientSession extends TcpSession
USE_EVENT_LOOP_FOR_PACKETS| Constructor and Description |
|---|
TcpClientSession(String host,
int port,
PacketProtocol protocol) |
TcpClientSession(String host,
int port,
PacketProtocol protocol,
ProxyInfo proxy) |
TcpClientSession(String host,
int port,
String bindAddress,
int bindPort,
PacketProtocol protocol) |
TcpClientSession(String host,
int port,
String bindAddress,
int bindPort,
PacketProtocol protocol,
ProxyInfo proxy) |
| Modifier and Type | Method and Description |
|---|---|
void |
connect(boolean wait)
Connects this session to its host and port.
|
void |
disconnect(String reason,
Throwable cause)
Disconnects the session.
|
PacketCodecHelper |
getCodecHelper()
Gets the session's
PacketCodecHelper. |
addListener, callEvent, callPacketReceived, callPacketSent, channelActive, channelInactive, connect, disconnect, enableEncryption, exceptionCaught, getChannel, getCompressionThreshold, getConnectTimeout, getFlag, getFlag, getFlags, getHost, getListeners, getLocalAddress, getPacketProtocol, getPort, getReadTimeout, getRemoteAddress, getWriteTimeout, hasFlag, isConnected, removeListener, send, setCompressionThreshold, setConnectTimeout, setFlag, setReadTimeout, setWriteTimeoutacceptInboundMessage, channelReadchannelReadComplete, channelRegistered, channelUnregistered, channelWritabilityChanged, userEventTriggeredhandlerAdded, handlerRemoved, isSharablepublic TcpClientSession(String host, int port, PacketProtocol protocol)
public TcpClientSession(String host, int port, PacketProtocol protocol, ProxyInfo proxy)
public TcpClientSession(String host, int port, String bindAddress, int bindPort, PacketProtocol protocol)
public TcpClientSession(String host, int port, String bindAddress, int bindPort, PacketProtocol protocol, ProxyInfo proxy)
public void connect(boolean wait)
Sessionconnect in interface Sessionconnect in class TcpSessionwait - Whether to wait for the connection to be established before returning.public PacketCodecHelper getCodecHelper()
SessionPacketCodecHelper.public void disconnect(String reason, Throwable cause)
Sessiondisconnect in interface Sessiondisconnect in class TcpSessionreason - Reason for disconnecting.cause - Throwable responsible for disconnecting.Copyright © 2022. All rights reserved.