// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: bgs/low/pb/client/rpc_types.proto
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using pb = Google.Protobuf;
using pbc = Google.Protobuf.Collections;
using pbr = Google.Protobuf.Reflection;
namespace Bgs.Protocol
{

    /// <summary>Holder for reflection information generated from bgs/low/pb/client/rpc_types.proto</summary>
    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public static partial class RpcTypesReflection
    {

        #region Descriptor
        /// <summary>File descriptor for bgs/low/pb/client/rpc_types.proto</summary>
        public static pbr::FileDescriptor Descriptor
        {
            get { return descriptor; }
        }
        private static pbr::FileDescriptor descriptor;

        static RpcTypesReflection()
        {
            byte[] descriptorData = System.Convert.FromBase64String(
                string.Concat(
                  "CiFiZ3MvbG93L3BiL2NsaWVudC9ycGNfdHlwZXMucHJvdG8SDGJncy5wcm90",
                  "b2NvbBo4YmdzL2xvdy9wYi9jbGllbnQvZ2xvYmFsX2V4dGVuc2lvbnMvbWV0",
                  "aG9kX29wdGlvbnMucHJvdG8aOWJncy9sb3cvcGIvY2xpZW50L2dsb2JhbF9l",
                  "eHRlbnNpb25zL3NlcnZpY2Vfb3B0aW9ucy5wcm90bxo3YmdzL2xvdy9wYi9j",
                  "bGllbnQvZ2xvYmFsX2V4dGVuc2lvbnMvZmllbGRfb3B0aW9ucy5wcm90byIN",
                  "CgtOT19SRVNQT05TRSIoCgdBZGRyZXNzEg8KB2FkZHJlc3MYASABKAkSDAoE",
                  "cG9ydBgCIAEoDSIpCglQcm9jZXNzSWQSDQoFbGFiZWwYASABKA0SDQoFZXBv",
                  "Y2gYAiABKA0iSQoNT2JqZWN0QWRkcmVzcxIlCgRob3N0GAEgASgLMhcuYmdz",
                  "LnByb3RvY29sLlByb2Nlc3NJZBIRCglvYmplY3RfaWQYAiABKAQiCAoGTm9E",
                  "YXRhInkKCUVycm9ySW5mbxIzCg5vYmplY3RfYWRkcmVzcxgBIAEoCzIbLmJn",
                  "cy5wcm90b2NvbC5PYmplY3RBZGRyZXNzEg4KBnN0YXR1cxgCIAEoDRIUCgxz",
                  "ZXJ2aWNlX2hhc2gYAyABKA0SEQoJbWV0aG9kX2lkGAQgASgNIoUCCgZIZWFk",
                  "ZXISEgoKc2VydmljZV9pZBgBIAEoDRIRCgltZXRob2RfaWQYAiABKA0SDQoF",
                  "dG9rZW4YAyABKA0SEQoJb2JqZWN0X2lkGAQgASgEEgwKBHNpemUYBSABKA0S",
                  "DgoGc3RhdHVzGAYgASgNEiYKBWVycm9yGAcgAygLMhcuYmdzLnByb3RvY29s",
                  "LkVycm9ySW5mbxIPCgd0aW1lb3V0GAggASgEEhMKC2lzX3Jlc3BvbnNlGAkg",
                  "ASgIEjAKD2ZvcndhcmRfdGFyZ2V0cxgKIAMoCzIXLmJncy5wcm90b2NvbC5Q",
                  "cm9jZXNzSWQSFAoMc2VydmljZV9oYXNoGAsgASgHQhsKDWJuZXQucHJvdG9j",
                  "b2xCCFJwY1Byb3RvSAJQAFABUAJiBnByb3RvMw=="));
            descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
                new pbr::FileDescriptor[] { Bgs.Protocol.MethodOptionsReflection.Descriptor, Bgs.Protocol.ServiceOptionsReflection.Descriptor, Bgs.Protocol.FieldOptionsReflection.Descriptor, },
                new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
            new pbr::GeneratedClrTypeInfo(typeof(Bgs.Protocol.NO_RESPONSE), Bgs.Protocol.NO_RESPONSE.Parser, null, null, null, null),
            new pbr::GeneratedClrTypeInfo(typeof(Bgs.Protocol.Address), Bgs.Protocol.Address.Parser, new[]{ "Address_", "Port" }, null, null, null),
            new pbr::GeneratedClrTypeInfo(typeof(Bgs.Protocol.ProcessId), Bgs.Protocol.ProcessId.Parser, new[]{ "Label", "Epoch" }, null, null, null),
            new pbr::GeneratedClrTypeInfo(typeof(Bgs.Protocol.ObjectAddress), Bgs.Protocol.ObjectAddress.Parser, new[]{ "Host", "ObjectId" }, null, null, null),
            new pbr::GeneratedClrTypeInfo(typeof(Bgs.Protocol.NoData), Bgs.Protocol.NoData.Parser, null, null, null, null),
            new pbr::GeneratedClrTypeInfo(typeof(Bgs.Protocol.ErrorInfo), Bgs.Protocol.ErrorInfo.Parser, new[]{ "ObjectAddress", "Status", "ServiceHash", "MethodId" }, null, null, null),
            new pbr::GeneratedClrTypeInfo(typeof(Bgs.Protocol.Header), Bgs.Protocol.Header.Parser, new[]{ "ServiceId", "MethodId", "Token", "ObjectId", "Size", "Status", "Error", "Timeout", "IsResponse", "ForwardTargets", "ServiceHash" }, null, null, null)
                }));
        }
        #endregion

    }
    #region Messages
    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public sealed partial class NO_RESPONSE : pb::IMessage<NO_RESPONSE>
    {
        private static readonly pb::MessageParser<NO_RESPONSE> _parser = new pb::MessageParser<NO_RESPONSE>(() => new NO_RESPONSE());
        public static pb::MessageParser<NO_RESPONSE> Parser { get { return _parser; } }

        public static pbr::MessageDescriptor Descriptor
        {
            get { return Bgs.Protocol.RpcTypesReflection.Descriptor.MessageTypes[0]; }
        }

        pbr::MessageDescriptor pb::IMessage.Descriptor
        {
            get { return Descriptor; }
        }

        public NO_RESPONSE()
        {
            OnConstruction();
        }

        partial void OnConstruction();

        public NO_RESPONSE(NO_RESPONSE other) : this()
        {
        }

        public NO_RESPONSE Clone()
        {
            return new NO_RESPONSE(this);
        }

        public override bool Equals(object other)
        {
            return Equals(other as NO_RESPONSE);
        }

        public bool Equals(NO_RESPONSE other)
        {
            if (ReferenceEquals(other, null))
            {
                return false;
            }
            if (ReferenceEquals(other, this))
            {
                return true;
            }
            return true;
        }

        public override int GetHashCode()
        {
            int hash = 1;
            return hash;
        }

        public override string ToString()
        {
            return pb::JsonFormatter.ToDiagnosticString(this);
        }

        public void WriteTo(pb::CodedOutputStream output)
        {
        }

        public int CalculateSize()
        {
            int size = 0;
            return size;
        }

        public void MergeFrom(NO_RESPONSE other)
        {
            if (other == null)
            {
                return;
            }
        }

        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                    default:
                        input.SkipLastField();
                        break;
                }
            }
        }

    }

    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public sealed partial class Address : pb::IMessage<Address>
    {
        private static readonly pb::MessageParser<Address> _parser = new pb::MessageParser<Address>(() => new Address());
        public static pb::MessageParser<Address> Parser { get { return _parser; } }

        public static pbr::MessageDescriptor Descriptor
        {
            get { return Bgs.Protocol.RpcTypesReflection.Descriptor.MessageTypes[1]; }
        }

        pbr::MessageDescriptor pb::IMessage.Descriptor
        {
            get { return Descriptor; }
        }

        public Address()
        {
            OnConstruction();
        }

        partial void OnConstruction();

        public Address(Address other) : this()
        {
            address_ = other.address_;
            port_ = other.port_;
        }

        public Address Clone()
        {
            return new Address(this);
        }

        /// <summary>Field number for the "address" field.</summary>
        public const int Address_FieldNumber = 1;
        private string address_ = "";
        public string Address_
        {
            get { return address_; }
            set
            {
                address_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
            }
        }

        /// <summary>Field number for the "port" field.</summary>
        public const int PortFieldNumber = 2;
        private uint port_;
        public uint Port
        {
            get { return port_; }
            set
            {
                port_ = value;
            }
        }

        public override bool Equals(object other)
        {
            return Equals(other as Address);
        }

        public bool Equals(Address other)
        {
            if (ReferenceEquals(other, null))
            {
                return false;
            }
            if (ReferenceEquals(other, this))
            {
                return true;
            }
            if (Address_ != other.Address_) return false;
            if (Port != other.Port) return false;
            return true;
        }

        public override int GetHashCode()
        {
            int hash = 1;
            if (Address_.Length != 0) hash ^= Address_.GetHashCode();
            if (Port != 0) hash ^= Port.GetHashCode();
            return hash;
        }

        public override string ToString()
        {
            return pb::JsonFormatter.ToDiagnosticString(this);
        }

        public void WriteTo(pb::CodedOutputStream output)
        {
            if (Address_.Length != 0)
            {
                output.WriteRawTag(10);
                output.WriteString(Address_);
            }
            if (Port != 0)
            {
                output.WriteRawTag(16);
                output.WriteUInt32(Port);
            }
        }

        public int CalculateSize()
        {
            int size = 0;
            if (Address_.Length != 0)
            {
                size += 1 + pb::CodedOutputStream.ComputeStringSize(Address_);
            }
            if (Port != 0)
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Port);
            }
            return size;
        }

        public void MergeFrom(Address other)
        {
            if (other == null)
            {
                return;
            }
            if (other.Address_.Length != 0)
            {
                Address_ = other.Address_;
            }
            if (other.Port != 0)
            {
                Port = other.Port;
            }
        }

        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                    default:
                        input.SkipLastField();
                        break;
                    case 10:
                        {
                            Address_ = input.ReadString();
                            break;
                        }
                    case 16:
                        {
                            Port = input.ReadUInt32();
                            break;
                        }
                }
            }
        }

    }

    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public sealed partial class ProcessId : pb::IMessage<ProcessId>
    {
        private static readonly pb::MessageParser<ProcessId> _parser = new pb::MessageParser<ProcessId>(() => new ProcessId());
        public static pb::MessageParser<ProcessId> Parser { get { return _parser; } }

        public static pbr::MessageDescriptor Descriptor
        {
            get { return Bgs.Protocol.RpcTypesReflection.Descriptor.MessageTypes[2]; }
        }

        pbr::MessageDescriptor pb::IMessage.Descriptor
        {
            get { return Descriptor; }
        }

        public ProcessId()
        {
            OnConstruction();
        }

        partial void OnConstruction();

        public ProcessId(ProcessId other) : this()
        {
            label_ = other.label_;
            epoch_ = other.epoch_;
        }

        public ProcessId Clone()
        {
            return new ProcessId(this);
        }

        /// <summary>Field number for the "label" field.</summary>
        public const int LabelFieldNumber = 1;
        private uint label_;
        public uint Label
        {
            get { return label_; }
            set
            {
                label_ = value;
            }
        }

        /// <summary>Field number for the "epoch" field.</summary>
        public const int EpochFieldNumber = 2;
        private uint epoch_;
        public uint Epoch
        {
            get { return epoch_; }
            set
            {
                epoch_ = value;
            }
        }

        public override bool Equals(object other)
        {
            return Equals(other as ProcessId);
        }

        public bool Equals(ProcessId other)
        {
            if (ReferenceEquals(other, null))
            {
                return false;
            }
            if (ReferenceEquals(other, this))
            {
                return true;
            }
            if (Label != other.Label) return false;
            if (Epoch != other.Epoch) return false;
            return true;
        }

        public override int GetHashCode()
        {
            int hash = 1;
            if (Label != 0) hash ^= Label.GetHashCode();
            if (Epoch != 0) hash ^= Epoch.GetHashCode();
            return hash;
        }

        public override string ToString()
        {
            return pb::JsonFormatter.ToDiagnosticString(this);
        }

        public void WriteTo(pb::CodedOutputStream output)
        {
            if (Label != 0)
            {
                output.WriteRawTag(8);
                output.WriteUInt32(Label);
            }
            if (Epoch != 0)
            {
                output.WriteRawTag(16);
                output.WriteUInt32(Epoch);
            }
        }

        public int CalculateSize()
        {
            int size = 0;
            if (Label != 0)
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Label);
            }
            if (Epoch != 0)
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Epoch);
            }
            return size;
        }

        public void MergeFrom(ProcessId other)
        {
            if (other == null)
            {
                return;
            }
            if (other.Label != 0)
            {
                Label = other.Label;
            }
            if (other.Epoch != 0)
            {
                Epoch = other.Epoch;
            }
        }

        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                    default:
                        input.SkipLastField();
                        break;
                    case 8:
                        {
                            Label = input.ReadUInt32();
                            break;
                        }
                    case 16:
                        {
                            Epoch = input.ReadUInt32();
                            break;
                        }
                }
            }
        }

    }

    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public sealed partial class ObjectAddress : pb::IMessage<ObjectAddress>
    {
        private static readonly pb::MessageParser<ObjectAddress> _parser = new pb::MessageParser<ObjectAddress>(() => new ObjectAddress());
        public static pb::MessageParser<ObjectAddress> Parser { get { return _parser; } }

        public static pbr::MessageDescriptor Descriptor
        {
            get { return Bgs.Protocol.RpcTypesReflection.Descriptor.MessageTypes[3]; }
        }

        pbr::MessageDescriptor pb::IMessage.Descriptor
        {
            get { return Descriptor; }
        }

        public ObjectAddress()
        {
            OnConstruction();
        }

        partial void OnConstruction();

        public ObjectAddress(ObjectAddress other) : this()
        {
            Host = other.host_ != null ? other.Host.Clone() : null;
            objectId_ = other.objectId_;
        }

        public ObjectAddress Clone()
        {
            return new ObjectAddress(this);
        }

        /// <summary>Field number for the "host" field.</summary>
        public const int HostFieldNumber = 1;
        private Bgs.Protocol.ProcessId host_;
        public Bgs.Protocol.ProcessId Host
        {
            get { return host_; }
            set
            {
                host_ = value;
            }
        }

        /// <summary>Field number for the "object_id" field.</summary>
        public const int ObjectIdFieldNumber = 2;
        private ulong objectId_;
        public ulong ObjectId
        {
            get { return objectId_; }
            set
            {
                objectId_ = value;
            }
        }

        public override bool Equals(object other)
        {
            return Equals(other as ObjectAddress);
        }

        public bool Equals(ObjectAddress other)
        {
            if (ReferenceEquals(other, null))
            {
                return false;
            }
            if (ReferenceEquals(other, this))
            {
                return true;
            }
            if (!object.Equals(Host, other.Host)) return false;
            if (ObjectId != other.ObjectId) return false;
            return true;
        }

        public override int GetHashCode()
        {
            int hash = 1;
            if (host_ != null) hash ^= Host.GetHashCode();
            if (ObjectId != 0UL) hash ^= ObjectId.GetHashCode();
            return hash;
        }

        public override string ToString()
        {
            return pb::JsonFormatter.ToDiagnosticString(this);
        }

        public void WriteTo(pb::CodedOutputStream output)
        {
            if (host_ != null)
            {
                output.WriteRawTag(10);
                output.WriteMessage(Host);
            }
            if (ObjectId != 0UL)
            {
                output.WriteRawTag(16);
                output.WriteUInt64(ObjectId);
            }
        }

        public int CalculateSize()
        {
            int size = 0;
            if (host_ != null)
            {
                size += 1 + pb::CodedOutputStream.ComputeMessageSize(Host);
            }
            if (ObjectId != 0UL)
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt64Size(ObjectId);
            }
            return size;
        }

        public void MergeFrom(ObjectAddress other)
        {
            if (other == null)
            {
                return;
            }
            if (other.host_ != null)
            {
                if (host_ == null)
                {
                    host_ = new Bgs.Protocol.ProcessId();
                }
                Host.MergeFrom(other.Host);
            }
            if (other.ObjectId != 0UL)
            {
                ObjectId = other.ObjectId;
            }
        }

        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                    default:
                        input.SkipLastField();
                        break;
                    case 10:
                        {
                            if (host_ == null)
                            {
                                host_ = new Bgs.Protocol.ProcessId();
                            }
                            input.ReadMessage(host_);
                            break;
                        }
                    case 16:
                        {
                            ObjectId = input.ReadUInt64();
                            break;
                        }
                }
            }
        }

    }

    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public sealed partial class NoData : pb::IMessage<NoData>
    {
        private static readonly pb::MessageParser<NoData> _parser = new pb::MessageParser<NoData>(() => new NoData());
        public static pb::MessageParser<NoData> Parser { get { return _parser; } }

        public static pbr::MessageDescriptor Descriptor
        {
            get { return Bgs.Protocol.RpcTypesReflection.Descriptor.MessageTypes[4]; }
        }

        pbr::MessageDescriptor pb::IMessage.Descriptor
        {
            get { return Descriptor; }
        }

        public NoData()
        {
            OnConstruction();
        }

        partial void OnConstruction();

        public NoData(NoData other) : this()
        {
        }

        public NoData Clone()
        {
            return new NoData(this);
        }

        public override bool Equals(object other)
        {
            return Equals(other as NoData);
        }

        public bool Equals(NoData other)
        {
            if (ReferenceEquals(other, null))
            {
                return false;
            }
            if (ReferenceEquals(other, this))
            {
                return true;
            }
            return true;
        }

        public override int GetHashCode()
        {
            int hash = 1;
            return hash;
        }

        public override string ToString()
        {
            return pb::JsonFormatter.ToDiagnosticString(this);
        }

        public void WriteTo(pb::CodedOutputStream output)
        {
        }

        public int CalculateSize()
        {
            int size = 0;
            return size;
        }

        public void MergeFrom(NoData other)
        {
            if (other == null)
            {
                return;
            }
        }

        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                    default:
                        input.SkipLastField();
                        break;
                }
            }
        }

    }

    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public sealed partial class ErrorInfo : pb::IMessage<ErrorInfo>
    {
        private static readonly pb::MessageParser<ErrorInfo> _parser = new pb::MessageParser<ErrorInfo>(() => new ErrorInfo());
        public static pb::MessageParser<ErrorInfo> Parser { get { return _parser; } }

        public static pbr::MessageDescriptor Descriptor
        {
            get { return Bgs.Protocol.RpcTypesReflection.Descriptor.MessageTypes[5]; }
        }

        pbr::MessageDescriptor pb::IMessage.Descriptor
        {
            get { return Descriptor; }
        }

        public ErrorInfo()
        {
            OnConstruction();
        }

        partial void OnConstruction();

        public ErrorInfo(ErrorInfo other) : this()
        {
            ObjectAddress = other.objectAddress_ != null ? other.ObjectAddress.Clone() : null;
            status_ = other.status_;
            serviceHash_ = other.serviceHash_;
            methodId_ = other.methodId_;
        }

        public ErrorInfo Clone()
        {
            return new ErrorInfo(this);
        }

        /// <summary>Field number for the "object_address" field.</summary>
        public const int ObjectAddressFieldNumber = 1;
        private Bgs.Protocol.ObjectAddress objectAddress_;
        public Bgs.Protocol.ObjectAddress ObjectAddress
        {
            get { return objectAddress_; }
            set
            {
                objectAddress_ = value;
            }
        }

        /// <summary>Field number for the "status" field.</summary>
        public const int StatusFieldNumber = 2;
        private uint status_;
        public uint Status
        {
            get { return status_; }
            set
            {
                status_ = value;
            }
        }

        /// <summary>Field number for the "service_hash" field.</summary>
        public const int ServiceHashFieldNumber = 3;
        private uint serviceHash_;
        public uint ServiceHash
        {
            get { return serviceHash_; }
            set
            {
                serviceHash_ = value;
            }
        }

        /// <summary>Field number for the "method_id" field.</summary>
        public const int MethodIdFieldNumber = 4;
        private uint methodId_;
        public uint MethodId
        {
            get { return methodId_; }
            set
            {
                methodId_ = value;
            }
        }

        public override bool Equals(object other)
        {
            return Equals(other as ErrorInfo);
        }

        public bool Equals(ErrorInfo other)
        {
            if (ReferenceEquals(other, null))
            {
                return false;
            }
            if (ReferenceEquals(other, this))
            {
                return true;
            }
            if (!object.Equals(ObjectAddress, other.ObjectAddress)) return false;
            if (Status != other.Status) return false;
            if (ServiceHash != other.ServiceHash) return false;
            if (MethodId != other.MethodId) return false;
            return true;
        }

        public override int GetHashCode()
        {
            int hash = 1;
            if (objectAddress_ != null) hash ^= ObjectAddress.GetHashCode();
            if (Status != 0) hash ^= Status.GetHashCode();
            if (ServiceHash != 0) hash ^= ServiceHash.GetHashCode();
            if (MethodId != 0) hash ^= MethodId.GetHashCode();
            return hash;
        }

        public override string ToString()
        {
            return pb::JsonFormatter.ToDiagnosticString(this);
        }

        public void WriteTo(pb::CodedOutputStream output)
        {
            if (objectAddress_ != null)
            {
                output.WriteRawTag(10);
                output.WriteMessage(ObjectAddress);
            }
            if (Status != 0)
            {
                output.WriteRawTag(16);
                output.WriteUInt32(Status);
            }
            if (ServiceHash != 0)
            {
                output.WriteRawTag(24);
                output.WriteUInt32(ServiceHash);
            }
            if (MethodId != 0)
            {
                output.WriteRawTag(32);
                output.WriteUInt32(MethodId);
            }
        }

        public int CalculateSize()
        {
            int size = 0;
            if (objectAddress_ != null)
            {
                size += 1 + pb::CodedOutputStream.ComputeMessageSize(ObjectAddress);
            }
            if (Status != 0)
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Status);
            }
            if (ServiceHash != 0)
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(ServiceHash);
            }
            if (MethodId != 0)
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(MethodId);
            }
            return size;
        }

        public void MergeFrom(ErrorInfo other)
        {
            if (other == null)
            {
                return;
            }
            if (other.objectAddress_ != null)
            {
                if (objectAddress_ == null)
                {
                    objectAddress_ = new Bgs.Protocol.ObjectAddress();
                }
                ObjectAddress.MergeFrom(other.ObjectAddress);
            }
            if (other.Status != 0)
            {
                Status = other.Status;
            }
            if (other.ServiceHash != 0)
            {
                ServiceHash = other.ServiceHash;
            }
            if (other.MethodId != 0)
            {
                MethodId = other.MethodId;
            }
        }

        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                    default:
                        input.SkipLastField();
                        break;
                    case 10:
                        {
                            if (objectAddress_ == null)
                            {
                                objectAddress_ = new Bgs.Protocol.ObjectAddress();
                            }
                            input.ReadMessage(objectAddress_);
                            break;
                        }
                    case 16:
                        {
                            Status = input.ReadUInt32();
                            break;
                        }
                    case 24:
                        {
                            ServiceHash = input.ReadUInt32();
                            break;
                        }
                    case 32:
                        {
                            MethodId = input.ReadUInt32();
                            break;
                        }
                }
            }
        }

    }

    [System.Diagnostics.DebuggerNonUserCodeAttribute()]
    public sealed partial class Header : pb::IMessage<Header>
    {
        private static readonly pb::MessageParser<Header> _parser = new pb::MessageParser<Header>(() => new Header());
        public static pb::MessageParser<Header> Parser { get { return _parser; } }

        public static pbr::MessageDescriptor Descriptor
        {
            get { return Bgs.Protocol.RpcTypesReflection.Descriptor.MessageTypes[6]; }
        }

        pbr::MessageDescriptor pb::IMessage.Descriptor
        {
            get { return Descriptor; }
        }

        public Header()
        {
            OnConstruction();
        }

        partial void OnConstruction();

        public Header(Header other) : this()
        {
            serviceId_ = other.serviceId_;
            methodId_ = other.methodId_;
            token_ = other.token_;
            objectId_ = other.objectId_;
            size_ = other.size_;
            status_ = other.status_;
            error_ = other.error_.Clone();
            timeout_ = other.timeout_;
            isResponse_ = other.isResponse_;
            forwardTargets_ = other.forwardTargets_.Clone();
            serviceHash_ = other.serviceHash_;
        }

        public Header Clone()
        {
            return new Header(this);
        }

        /// <summary>Field number for the "service_id" field.</summary>
        public const int ServiceIdFieldNumber = 0;
        private uint serviceId_;
        public uint ServiceId
        {
            get { return serviceId_; }
            set
            {
                bitArray.Set(ServiceIdFieldNumber, true);
                serviceId_ = value;
            }
        }

        /// <summary>Field number for the "method_id" field.</summary>
        public const int MethodIdFieldNumber = 1;
        private uint methodId_;
        public uint MethodId
        {
            get { return methodId_; }
            set
            {
                bitArray.Set(MethodIdFieldNumber, true);
                methodId_ = value;
            }
        }

        /// <summary>Field number for the "token" field.</summary>
        public const int TokenFieldNumber = 2;
        private uint token_;
        public uint Token
        {
            get { return token_; }
            set
            {
                bitArray.Set(TokenFieldNumber, true);
                token_ = value;
            }
        }

        /// <summary>Field number for the "object_id" field.</summary>
        public const int ObjectIdFieldNumber = 3;
        private ulong objectId_;
        public ulong ObjectId
        {
            get { return objectId_; }
            set
            {
                bitArray.Set(ObjectIdFieldNumber, true);
                objectId_ = value;
            }
        }

        /// <summary>Field number for the "size" field.</summary>
        public const int SizeFieldNumber = 4;
        private uint size_;
        public uint Size
        {
            get { return size_; }
            set
            {
                bitArray.Set(SizeFieldNumber, true);
                size_ = value;
            }
        }

        /// <summary>Field number for the "status" field.</summary>
        public const int StatusFieldNumber = 5;
        private uint status_;
        public uint Status
        {
            get { return status_; }
            set
            {
                bitArray.Set(StatusFieldNumber, true);
                status_ = value;
            }
        }

        /// <summary>Field number for the "error" field.</summary>
        public const int ErrorFieldNumber = 6;
        private static readonly pb::FieldCodec<Bgs.Protocol.ErrorInfo> _repeated_error_codec
            = pb::FieldCodec.ForMessage(58, Bgs.Protocol.ErrorInfo.Parser);
        private readonly pbc::RepeatedField<Bgs.Protocol.ErrorInfo> error_ = new pbc::RepeatedField<Bgs.Protocol.ErrorInfo>();
        public pbc::RepeatedField<Bgs.Protocol.ErrorInfo> Error
        {
            get { return error_; }
        }

        /// <summary>Field number for the "timeout" field.</summary>
        public const int TimeoutFieldNumber = 7;
        private ulong timeout_;
        public ulong Timeout
        {
            get { return timeout_; }
            set
            {
                bitArray.Set(TimeoutFieldNumber, true);
                timeout_ = value;
            }
        }

        /// <summary>Field number for the "is_response" field.</summary>
        public const int IsResponseFieldNumber = 8;
        private bool isResponse_;
        public bool IsResponse
        {
            get { return isResponse_; }
            set
            {
                bitArray.Set(IsResponseFieldNumber, true);
                isResponse_ = value;
            }
        }

        /// <summary>Field number for the "forward_targets" field.</summary>
        public const int ForwardTargetsFieldNumber = 9;
        private static readonly pb::FieldCodec<Bgs.Protocol.ProcessId> _repeated_forwardTargets_codec
            = pb::FieldCodec.ForMessage(82, Bgs.Protocol.ProcessId.Parser);
        private readonly pbc::RepeatedField<Bgs.Protocol.ProcessId> forwardTargets_ = new pbc::RepeatedField<Bgs.Protocol.ProcessId>();
        public pbc::RepeatedField<Bgs.Protocol.ProcessId> ForwardTargets
        {
            get { return forwardTargets_; }
        }

        /// <summary>Field number for the "service_hash" field.</summary>
        public const int ServiceHashFieldNumber = 10;
        private uint serviceHash_;
        public uint ServiceHash
        {
            get { return serviceHash_; }
            set
            {
                bitArray.Set(ServiceHashFieldNumber, true);
                serviceHash_ = value;
            }
        }

        public override bool Equals(object other)
        {
            return Equals(other as Header);
        }

        public bool Equals(Header other)
        {
            if (ReferenceEquals(other, null))
            {
                return false;
            }
            if (ReferenceEquals(other, this))
            {
                return true;
            }
            if (ServiceId != other.ServiceId) return false;
            if (MethodId != other.MethodId) return false;
            if (Token != other.Token) return false;
            if (ObjectId != other.ObjectId) return false;
            if (Size != other.Size) return false;
            if (Status != other.Status) return false;
            if (!error_.Equals(other.error_)) return false;
            if (Timeout != other.Timeout) return false;
            if (IsResponse != other.IsResponse) return false;
            if (!forwardTargets_.Equals(other.forwardTargets_)) return false;
            if (ServiceHash != other.ServiceHash) return false;
            return true;
        }

        public override int GetHashCode()
        {
            int hash = 1;
            if (ServiceId != 0) hash ^= ServiceId.GetHashCode();
            if (MethodId != 0) hash ^= MethodId.GetHashCode();
            if (Token != 0) hash ^= Token.GetHashCode();
            if (ObjectId != 0UL) hash ^= ObjectId.GetHashCode();
            if (Size != 0) hash ^= Size.GetHashCode();
            if (Status != 0) hash ^= Status.GetHashCode();
            hash ^= error_.GetHashCode();
            if (Timeout != 0UL) hash ^= Timeout.GetHashCode();
            if (IsResponse != false) hash ^= IsResponse.GetHashCode();
            hash ^= forwardTargets_.GetHashCode();
            if (ServiceHash != 0) hash ^= ServiceHash.GetHashCode();
            return hash;
        }

        public override string ToString()
        {
            return pb::JsonFormatter.ToDiagnosticString(this);
        }

        public void WriteTo(pb::CodedOutputStream output)
        {
            if (bitArray.Get(ServiceIdFieldNumber))
            {
                output.WriteRawTag(8);
                output.WriteUInt32(ServiceId);
            }
            if (bitArray.Get(MethodIdFieldNumber))
            {
                output.WriteRawTag(16);
                output.WriteUInt32(MethodId);
            }
            if (bitArray.Get(TokenFieldNumber))
            {
                output.WriteRawTag(24);
                output.WriteUInt32(Token);
            }
            if (bitArray.Get(ObjectIdFieldNumber))
            {
                output.WriteRawTag(32);
                output.WriteUInt64(ObjectId);
            }
            if (bitArray.Get(SizeFieldNumber))
            {
                output.WriteRawTag(40);
                output.WriteUInt32(Size);
            }
            if (bitArray.Get(StatusFieldNumber))
            {
                output.WriteRawTag(48);
                output.WriteUInt32(Status);
            }
            error_.WriteTo(output, _repeated_error_codec);
            if (bitArray.Get(TimeoutFieldNumber))
            {
                output.WriteRawTag(64);
                output.WriteUInt64(Timeout);
            }
            if (bitArray.Get(IsResponseFieldNumber))
            {
                output.WriteRawTag(72);
                output.WriteBool(IsResponse);
            }
            forwardTargets_.WriteTo(output, _repeated_forwardTargets_codec);
            if (bitArray.Get(ServiceHashFieldNumber))
            {
                output.WriteRawTag(93);
                output.WriteFixed32(ServiceHash);
            }
        }

        public int CalculateSize()
        {
            int size = 0;
            if (bitArray.Get(ServiceIdFieldNumber))
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(ServiceId);
            }
            if (bitArray.Get(MethodIdFieldNumber))
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(MethodId);
            }
            if (bitArray.Get(TokenFieldNumber))
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Token);
            }
            if (bitArray.Get(ObjectIdFieldNumber))
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt64Size(ObjectId);
            }
            if (bitArray.Get(SizeFieldNumber))
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Size);
            }
            if (bitArray.Get(StatusFieldNumber))
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Status);
            }
            size += error_.CalculateSize(_repeated_error_codec);
            if (bitArray.Get(TimeoutFieldNumber))
            {
                size += 1 + pb::CodedOutputStream.ComputeUInt64Size(Timeout);
            }
            if (bitArray.Get(IsResponseFieldNumber))
            {
                size += 1 + 1;
            }
            size += forwardTargets_.CalculateSize(_repeated_forwardTargets_codec);
            if (bitArray.Get(ServiceHashFieldNumber))
            {
                size += 1 + 4;
            }
            return size;
        }

        public void MergeFrom(Header other)
        {
            if (other == null)
            {
                return;
            }
            if (other.ServiceId != 0)
            {
                ServiceId = other.ServiceId;
            }
            if (other.MethodId != 0)
            {
                MethodId = other.MethodId;
            }
            if (other.Token != 0)
            {
                Token = other.Token;
            }
            if (other.ObjectId != 0UL)
            {
                ObjectId = other.ObjectId;
            }
            if (other.Size != 0)
            {
                Size = other.Size;
            }
            if (other.Status != 0)
            {
                Status = other.Status;
            }
            error_.Add(other.error_);
            if (other.Timeout != 0UL)
            {
                Timeout = other.Timeout;
            }
            if (other.IsResponse != false)
            {
                IsResponse = other.IsResponse;
            }
            forwardTargets_.Add(other.forwardTargets_);
            if (other.ServiceHash != 0)
            {
                ServiceHash = other.ServiceHash;
            }
        }

        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;
            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                    default:
                        input.SkipLastField();
                        break;
                    case 8:
                        {
                            ServiceId = input.ReadUInt32();
                            break;
                        }
                    case 16:
                        {
                            MethodId = input.ReadUInt32();
                            break;
                        }
                    case 24:
                        {
                            Token = input.ReadUInt32();
                            break;
                        }
                    case 32:
                        {
                            ObjectId = input.ReadUInt64();
                            break;
                        }
                    case 40:
                        {
                            Size = input.ReadUInt32();
                            break;
                        }
                    case 48:
                        {
                            Status = input.ReadUInt32();
                            break;
                        }
                    case 58:
                        {
                            error_.AddEntriesFrom(input, _repeated_error_codec);
                            break;
                        }
                    case 64:
                        {
                            Timeout = input.ReadUInt64();
                            break;
                        }
                    case 72:
                        {
                            IsResponse = input.ReadBool();
                            break;
                        }
                    case 82:
                        {
                            forwardTargets_.AddEntriesFrom(input, _repeated_forwardTargets_codec);
                            break;
                        }
                    case 93:
                        {
                            ServiceHash = input.ReadFixed32();
                            break;
                        }
                }
            }
        }

        System.Collections.BitArray bitArray = new System.Collections.BitArray(11);
    }

    #endregion

}

#endregion Designer generated code
