public void Write(BridgeStream bridgeStream)
        {
            if (bridgeStream == null)
            {
                Write(0);
                return;
            }

            var data = bridgeStream.Encode();

            Write(data);
        }
        public void TestInt()
        {
            _sendBridgeStream.Write(10);
            var data          = _sendBridgeStream.Encode();
            var receivePacket = new BridgeStream(data);
            var sendValue     = receivePacket.ReadInt();

            Assert.AreEqual(10, sendValue);
        }