public void Setup()
 {
     m_net_socket = new IOCPNetAccepter();
     m_net_socket.Setup();
     m_msg_proc = new ClientMsgProc();
     m_msg_proc.Setup();
     m_send_by = NetUtils.AllocSendPacket();
     this.RegisterEvent();
 }
 public void Destroy()
 {
     this.UnRegisterEvent();
     if (m_msg_proc != null)
     {
         m_msg_proc.Destroy();
         m_msg_proc = null;
     }
     if (m_net_socket != null)
     {
         m_net_socket.Destroy();
         m_net_socket = null;
     }
 }