类 BrokerClient
java.lang.Object
com.iohao.game.bolt.broker.core.client.BrokerClient
- 所有已实现的接口:
BrokerClientContext
,ChannelContext
,SimpleServer
,GroupWith
,AttrOptionDynamic
public class BrokerClient
extends Object
implements BrokerClientContext, GroupWith, AttrOptionDynamic
BrokerClient 是与 broker(游戏网关)通信的 client
对外服、逻辑服都是 broker 的 client
see BrokerClientBuilder.build()
- 作者:
- 渔民小镇
- 另请参阅:
- 日期:
- 2022-05-14
-
方法概要
修饰符和类型方法说明框架网络通讯聚合接口简单的服务器信息void
init()
<T> T
invokeSync
(Object request) Synchronous invocation<T> T
invokeSync
(Object request, int timeoutMillis) static BrokerClientBuilder
void
发送消息到游戏网关void
sendResponse
(Object responseObject) 发送响应给请求端void
setWithNo
(int withNo) 从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
从接口继承的方法 com.iohao.game.common.kit.attr.AttrOptionDynamic
getOptions, ifNull, ifPresent, option, option, optionValue
从接口继承的方法 com.iohao.game.action.skeleton.core.commumication.BrokerClientContext
getBroadcastContext, getBroadcastOrderContext, getId, getInvokeExternalModuleContext, getInvokeModuleContext, getProcessorContext
-
方法详细资料
-
newBuilder
-
init
public void init() -
getCommunicationAggregationContext
从接口复制的说明:BrokerClientContext
框架网络通讯聚合接口- 指定者:
getCommunicationAggregationContext
在接口中BrokerClientContext
- 返回:
- 框架网络通信聚合接口
-
invokeSync
public <T> T invokeSync(Object request, int timeoutMillis) throws com.alipay.remoting.exception.RemotingException, InterruptedException - 抛出:
com.alipay.remoting.exception.RemotingException
InterruptedException
-
invokeSync
public <T> T invokeSync(Object request) throws com.alipay.remoting.exception.RemotingException, InterruptedException 从接口复制的说明:BrokerClientContext
Synchronous invocation- 指定者:
invokeSync
在接口中BrokerClientContext
- 类型参数:
T
- t- 参数:
request
- request- 返回:
- response object
- 抛出:
com.alipay.remoting.exception.RemotingException
InterruptedException
-
oneway
从接口复制的说明:BrokerClientContext
发送消息到游戏网关- 指定者:
oneway
在接口中BrokerClientContext
- 参数:
request
- 消息- 抛出:
Exception
- e
-
getSimpleServerInfo
从接口复制的说明:SimpleServer
简单的服务器信息- 指定者:
getSimpleServerInfo
在接口中SimpleServer
- 返回:
- 简单的服务器信息
-
sendResponse
从接口复制的说明:ChannelContext
发送响应给请求端- 指定者:
sendResponse
在接口中ChannelContext
- 参数:
responseObject
- 响应对象
-
setWithNo
public void setWithNo(int withNo)
-