Ejemplo n.º 1
0
        public int Send(DSMsg dsMsg)
        {
            int result = (int)InteralDS21.DSSendData((ushort)dsMsg.ScrType, dsMsg.ScrID,
                                                     (ushort)dsMsg.DestType, dsMsg.DestID,
                                                     0, 0, dsMsg.SerialNo, dsMsg.Reserved, dsMsg.MsgID, (uint)dsMsg.StrData.Length, dsMsg.StrData);

            return(result);
        }
Ejemplo n.º 2
0
        void dsNetCtrlEx_OnNewMessage(int nMsgCount)
        {
            int    count = nMsgCount;
            ushort nSrcType, nSrcID, nDestType, nDestID, nMsgType, nMsgID;
            string strData;
            uint   nSerialNo, nReserved;

            while (count > 0)
            {
                try
                {
                    int i = InteralDS21.GetNewMessageEx(out nSrcType, out nSrcID, out nDestType, out nDestID,
                                                        out nMsgType, out nSerialNo, out nReserved, out nMsgID, out strData);
                    DSMsg dsMsg = new DSMsg()
                    {
                        DestID   = nDestID,
                        DestType = nDestType,
                        MsgID    = nMsgID,
                        MsgType  = nMsgType,
                        Reserved = nReserved,
                        ScrID    = nSrcID,
                        ScrType  = nSrcType,
                        SerialNo = nSerialNo,
                        StrData  = strData
                    };
                    switch (dsMsg.DSMessageCode)
                    {
                    case DSMessageCode.SystemGeneral:
                    {
                        break;
                    }

                    case DSMessageCode.SystemXml:
                    {
                        break;
                    }

                    case DSMessageCode.SystemInternal:
                    {
                        break;
                    }
                    }
                }
                catch (Exception e)
                {
                }
            }
        }
Ejemplo n.º 3
0
        public DSMsg ToDSMsg()
        {
            DSMsg msg = new DSMsg()
            {
                DestID   = DestAgentID,
                DestType = (ushort)DestNodeType,
                MsgID    = (ushort)this.MsgID,
                ScrID    = SrcAgentID,
                ScrType  = (ushort)SrcNodeType,
                MsgType  = 0,//////暂时不知道做什么用的
                SerialNo = 0,
                StrData  = this.StrData,
                Reserved = (uint)this.ReserveID
            };

            return(msg);
        }
Ejemplo n.º 4
0
 public void Handler(DSMsg dsmsg)
 {
     throw new NotImplementedException();
 }
Ejemplo n.º 5
0
 void IDS21.Send(DSMsg dsMsg)
 {
     throw new NotImplementedException();
 }
Ejemplo n.º 6
0
 public int Send(DSMsg dsmsg)
 {
     throw new NotImplementedException();
 }