public class TioClient extends Object
| 构造器和说明 |
|---|
TioClient(TioClientConfig tioClientConfig) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
asyncConnect(Node serverNode)
asyncConnect
|
void |
asyncConnect(Node serverNode,
Integer timeout)
asyncConnect
|
void |
asyncConnect(Node serverNode,
String bindIp,
Integer bindPort,
Integer timeout)
asyncConnect
|
ClientChannelContext |
connect(Node serverNode)
connect
|
ClientChannelContext |
connect(Node serverNode,
Integer timeout)
connect
|
ClientChannelContext |
connect(Node serverNode,
String bindIp,
Integer bindPort,
ClientChannelContext initClientChannelContext,
Integer timeout)
connect
|
ClientChannelContext |
connect(Node serverNode,
String bindIp,
Integer bindPort,
Integer timeout) |
AsynchronousChannelGroup |
getChannelGroup() |
TioClientConfig |
getTioClientConfig() |
void |
reconnect(ClientChannelContext channelContext,
Integer timeout) |
boolean |
stop()
停止
|
public TioClient(TioClientConfig tioClientConfig) throws IOException
tioClientConfig - TioClientConfigIOException - IOExceptionpublic void asyncConnect(Node serverNode) throws Exception
serverNode - serverNodeException - Exceptionpublic void asyncConnect(Node serverNode, Integer timeout) throws Exception
serverNode - serverNodetimeout - timeoutException - Exceptionpublic void asyncConnect(Node serverNode, String bindIp, Integer bindPort, Integer timeout) throws Exception
serverNode - serverNodebindIp - bindIpbindPort - bindPorttimeout - timeoutException - Exceptionpublic ClientChannelContext connect(Node serverNode) throws Exception
serverNode - serverNodeException - Exceptionpublic ClientChannelContext connect(Node serverNode, Integer timeout) throws Exception
serverNode - serverNodetimeout - timeoutException - Exceptionpublic ClientChannelContext connect(Node serverNode, String bindIp, Integer bindPort, ClientChannelContext initClientChannelContext, Integer timeout) throws Exception
serverNode - serverNodebindIp - bindIpbindPort - bindPortinitClientChannelContext - initClientChannelContexttimeout - 超时时间,单位秒Exception - Exceptionpublic ClientChannelContext connect(Node serverNode, String bindIp, Integer bindPort, Integer timeout) throws Exception
serverNode - NodebindIp - bindIpbindPort - bindPorttimeout - 超时时间,单位秒Exception - Exceptionpublic AsynchronousChannelGroup getChannelGroup()
public TioClientConfig getTioClientConfig()
public void reconnect(ClientChannelContext channelContext, Integer timeout) throws Exception
channelContext - timeout - 单位秒Exception - Exceptionpublic boolean stop()
Copyright © 2023. All rights reserved.