private void SendPongpacket(int pingRequestId, long pingTime)
        {
            SendPacket((int)OpCode.Pong, _settings.Protocol,
                       PacketDataFactory.GetTimestampPong(pingRequestId, pingTime));

            OnLogEntry(LogEntryFactory.CreatePongSentEntryLog(pingRequestId, (int)OpCode.Pong));
        }
        /**
         * <summary>Send Ping</summary>
         * <remark>This ping is intented to measure the latency and
         * round trip of the active clients in the real time session.
         * This is not a reflection of the client / server connection.</remark>
         */
        public void SendPing()
        {
            if (!_rtConnected)
            {
                return;
            }
            var r = GetNextRequestId();

            SendPacket((int)OpCode.Ping, _settings.Protocol, PacketDataFactory.GetTimestampPing(r));
            OnLogEntry(LogEntryFactory.CreatePingSentEntryLog(r, (int)OpCode.Ping));
        }
        /**
         * <summary>Send Unstructured Packet</summary>
         * <param name="opCode">OpCode to send the packet on</param>
         */
        public void SendUnstructuredDataPacket(int opCode)
        {
            if (!_rtConnected)
            {
                return;
            }
            var r = GetNextRequestId();

            SendPacket(opCode, _settings.Protocol, PacketDataFactory.GetUnstructuredData(r));
            OnLogEntry(LogEntryFactory.CreateBlankSentLogEntry(r, opCode));
        }