public static SubscribeResponse DeserializeLengthDelimited(Stream stream)
        {
            SubscribeResponse subscribeResponse = new SubscribeResponse();

            SubscribeResponse.DeserializeLengthDelimited(stream, subscribeResponse);
            return(subscribeResponse);
        }
        public static SubscribeResponse DeserializeLengthDelimited(Stream stream, SubscribeResponse instance)
        {
            long position = (long)ProtocolParser.ReadUInt32(stream);

            position += stream.Position;
            return(SubscribeResponse.Deserialize(stream, instance, position));
        }
        public static SubscribeResponse DeserializeLengthDelimited(Stream stream, SubscribeResponse instance)
        {
            long num = (long)((ulong)ProtocolParser.ReadUInt32(stream));

            num += stream.get_Position();
            return(SubscribeResponse.Deserialize(stream, instance, num));
        }
 public static SubscribeResponse Deserialize(Stream stream, SubscribeResponse instance, long limit)
 {
     while (limit < 0L || stream.Position < limit)
     {
         int num = stream.ReadByte();
         if (num == -1)
         {
             if (limit >= 0L)
             {
                 throw new EndOfStreamException();
             }
             return(instance);
         }
         else if (num != 8)
         {
             Key  key   = ProtocolParser.ReadKey((byte)num, stream);
             uint field = key.Field;
             if (field == 0u)
             {
                 throw new ProtocolBufferException("Invalid field id: 0, something went wrong in the stream");
             }
             ProtocolParser.SkipKey(stream, key);
         }
         else
         {
             instance.SubscriptionId = ProtocolParser.ReadUInt64(stream);
         }
     }
     if (stream.Position == limit)
     {
         return(instance);
     }
     throw new ProtocolBufferException("Read past max limit");
 }
 public static void Serialize(Stream stream, SubscribeResponse instance)
 {
     if (instance.HasSubscriptionId)
     {
         stream.WriteByte(8);
         ProtocolParser.WriteUInt64(stream, instance.SubscriptionId);
     }
 }
        public override bool Equals(object obj)
        {
            SubscribeResponse subscribeResponse = obj as SubscribeResponse;

            if (subscribeResponse == null)
            {
                return(false);
            }
            if (this.HasSubscriptionId == subscribeResponse.HasSubscriptionId && (!this.HasSubscriptionId || this.SubscriptionId.Equals(subscribeResponse.SubscriptionId)))
            {
                return(true);
            }
            return(false);
        }
 public static SubscribeResponse Deserialize(Stream stream, SubscribeResponse instance)
 {
     return(SubscribeResponse.Deserialize(stream, instance, (long)-1));
 }
 public void Deserialize(Stream stream)
 {
     SubscribeResponse.Deserialize(stream, this);
 }
        public override bool Equals(object obj)
        {
            SubscribeResponse subscribeResponse = obj as SubscribeResponse;

            return(subscribeResponse != null && this.HasSubscriptionId == subscribeResponse.HasSubscriptionId && (!this.HasSubscriptionId || this.SubscriptionId.Equals(subscribeResponse.SubscriptionId)));
        }