Beispiel #1
0
 private void PackageManage_ForwardRequestReceived(object sender, PackageEventArgs e)
 {
     ForwardRequest(this, e);
 }
Beispiel #2
0
        private void PackageManage_LoginRequestReceived(object sender, PackageEventArgs e)
        {
            LoginReqPackage lrp = (LoginReqPackage)e.Package;

            Id = lrp.DeviceId;

            byte[] loginRespBytes = new LoginRespPackage().GetBytes();

            Send(loginRespBytes);
            DataSent(this, new SocketCommunicationEventArgs(loginRespBytes));
        }
Beispiel #3
0
        private void PackageManage_CallRequestReceived(object sender, PackageEventArgs e)
        {
            Random rnd = new Random();
            byte[] callRespBytes = new CallRespPackage(true, rnd.Next()).GetBytes();

            Send(callRespBytes);
            DataSent(this, new SocketCommunicationEventArgs(callRespBytes));
        }
Beispiel #4
0
        private void PackageManage_PingReceived(object sender, PackageEventArgs e)
        {
            byte[] pongBytes = new PongPackage().GetBytes();

            Send(pongBytes);
            DataSent(this, new SocketCommunicationEventArgs(pongBytes));
        }