IMessageHandler 接口
表示消息处理器的接口,处理特定类型的消息。
命名空间: Fantasy.Network.Interface
程序集: Fantasy.Net.dll
语法
public interface IMessageHandler
方法
| 编辑本文 查看源代码Handle(Session, uint, uint, object)
处理消息的方法。
声明
FTask Handle(Session session, uint rpcId, uint messageTypeCode, object message)
参数
类型 | 名称 | 描述 |
---|---|---|
Session | session | 会话对象。 |
uint | rpcId | RPC标识。 |
uint | messageTypeCode | 消息类型代码。 |
object | message | 要处理的消息。 |
返回
类型 | 描述 |
---|---|
FTask | 异步任务。 |
Type()
获取处理的消息类型。
声明
Type Type()
返回
类型 | 描述 |
---|---|
Type | 消息类型。 |