public static bool MsgCreater(UInt16 type, UInt16 id, ref CSLib.Framework.CMessage msg) { Message.EMsgType msgType = (Message.EMsgType)type; switch (msgType) { case Message.EMsgType.EMT_SAMPLE: { return(_SampleMsgCreater(id, ref msg)); } } return(false); }
// private bool _CreateMsgExecFun(UInt16 type, UInt16 id, ref CSLib.Framework.DMsgExecFunc msgExecut) { Message.EMsgType msgType = (Message.EMsgType)type; switch (msgType) { case Message.EMsgType.EMT_SAMPLE: { return(_SampleMsgExecFun(id, ref msgExecut)); } } Console.WriteLine("无法解析的消息类型{0}", type); return(false); }