예제 #1
0
 /// <summary>
 /// 设置消息数据
 /// </summary>
 /// <param name="model">消息model</param>
 public void SetData(object model)
 {
     this.Data = SerializerUtils.Serialize(model);
 }
예제 #2
0
 /// <summary>
 /// 序列化消息
 /// </summary>
 /// <returns></returns>
 public byte[] Serialize()
 {
     return(SerializerUtils.Serialize(this));
 }