类 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
-
方法概要
修饰符和类型方法说明框架网络通讯聚合接口简单的服务器信息voidinit()<T> TinvokeSync(Object request) Synchronous invocation<T> TinvokeSync(Object request, int timeoutMillis) static BrokerClientBuildervoid发送消息到游戏网关voidsendResponse(Object responseObject) 发送响应给请求端voidsetWithNo(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.RemotingExceptionInterruptedException
-
invokeSync
public <T> T invokeSync(Object request) throws com.alipay.remoting.exception.RemotingException, InterruptedException 从接口复制的说明:BrokerClientContextSynchronous invocation- 指定者:
invokeSync在接口中BrokerClientContext- 类型参数:
T- t- 参数:
request- request- 返回:
- response object
- 抛出:
com.alipay.remoting.exception.RemotingExceptionInterruptedException
-
oneway
从接口复制的说明:BrokerClientContext发送消息到游戏网关- 指定者:
oneway在接口中BrokerClientContext- 参数:
request- 消息- 抛出:
Exception- e
-
getSimpleServerInfo
从接口复制的说明:SimpleServer简单的服务器信息- 指定者:
getSimpleServerInfo在接口中SimpleServer- 返回:
- 简单的服务器信息
-
sendResponse
从接口复制的说明:ChannelContext发送响应给请求端- 指定者:
sendResponse在接口中ChannelContext- 参数:
responseObject- 响应对象
-
setWithNo
public void setWithNo(int withNo)
-