using System; using Model; namespace Model { public interface IMessageDispather { ushort GetOpcode(Type type); void RegisterHandler(ushort opcode, Action action) where Message : AMessage; void RegisterRpcHandler(ushort opcode, Action> action) where Request : ARequest where Response : AResponse; } public interface IMRegister { void Register(IMessageDispather messageDispather); } }