1 // Generated by the protocol buffer compiler.  DO NOT EDIT!
2 // source: google/protobuf/type.proto
3 #pragma warning disable 1591, 0612, 3021
4 #region Designer generated code
5 
6 using pb = global::Google.Protobuf;
7 using pbc = global::Google.Protobuf.Collections;
8 using pbr = global::Google.Protobuf.Reflection;
9 using scg = global::System.Collections.Generic;
10 namespace Google.Protobuf.WellKnownTypes {
11 
12   /// <summary>Holder for reflection information generated from google/protobuf/type.proto</summary>
13   public static partial class TypeReflection {
14 
15     #region Descriptor
16     /// <summary>File descriptor for google/protobuf/type.proto</summary>
17     public static pbr::FileDescriptor Descriptor {
18       get { return descriptor; }
19     }
20     private static pbr::FileDescriptor descriptor;
21 
TypeReflection()22     static TypeReflection() {
23       byte[] descriptorData = global::System.Convert.FromBase64String(
24           string.Concat(
25             "Chpnb29nbGUvcHJvdG9idWYvdHlwZS5wcm90bxIPZ29vZ2xlLnByb3RvYnVm",
26             "Ghlnb29nbGUvcHJvdG9idWYvYW55LnByb3RvGiRnb29nbGUvcHJvdG9idWYv",
27             "c291cmNlX2NvbnRleHQucHJvdG8i1wEKBFR5cGUSDAoEbmFtZRgBIAEoCRIm",
28             "CgZmaWVsZHMYAiADKAsyFi5nb29nbGUucHJvdG9idWYuRmllbGQSDgoGb25l",
29             "b2ZzGAMgAygJEigKB29wdGlvbnMYBCADKAsyFy5nb29nbGUucHJvdG9idWYu",
30             "T3B0aW9uEjYKDnNvdXJjZV9jb250ZXh0GAUgASgLMh4uZ29vZ2xlLnByb3Rv",
31             "YnVmLlNvdXJjZUNvbnRleHQSJwoGc3ludGF4GAYgASgOMhcuZ29vZ2xlLnBy",
32             "b3RvYnVmLlN5bnRheCLVBQoFRmllbGQSKQoEa2luZBgBIAEoDjIbLmdvb2ds",
33             "ZS5wcm90b2J1Zi5GaWVsZC5LaW5kEjcKC2NhcmRpbmFsaXR5GAIgASgOMiIu",
34             "Z29vZ2xlLnByb3RvYnVmLkZpZWxkLkNhcmRpbmFsaXR5Eg4KBm51bWJlchgD",
35             "IAEoBRIMCgRuYW1lGAQgASgJEhAKCHR5cGVfdXJsGAYgASgJEhMKC29uZW9m",
36             "X2luZGV4GAcgASgFEg4KBnBhY2tlZBgIIAEoCBIoCgdvcHRpb25zGAkgAygL",
37             "MhcuZ29vZ2xlLnByb3RvYnVmLk9wdGlvbhIRCglqc29uX25hbWUYCiABKAkS",
38             "FQoNZGVmYXVsdF92YWx1ZRgLIAEoCSLIAgoES2luZBIQCgxUWVBFX1VOS05P",
39             "V04QABIPCgtUWVBFX0RPVUJMRRABEg4KClRZUEVfRkxPQVQQAhIOCgpUWVBF",
40             "X0lOVDY0EAMSDwoLVFlQRV9VSU5UNjQQBBIOCgpUWVBFX0lOVDMyEAUSEAoM",
41             "VFlQRV9GSVhFRDY0EAYSEAoMVFlQRV9GSVhFRDMyEAcSDQoJVFlQRV9CT09M",
42             "EAgSDwoLVFlQRV9TVFJJTkcQCRIOCgpUWVBFX0dST1VQEAoSEAoMVFlQRV9N",
43             "RVNTQUdFEAsSDgoKVFlQRV9CWVRFUxAMEg8KC1RZUEVfVUlOVDMyEA0SDQoJ",
44             "VFlQRV9FTlVNEA4SEQoNVFlQRV9TRklYRUQzMhAPEhEKDVRZUEVfU0ZJWEVE",
45             "NjQQEBIPCgtUWVBFX1NJTlQzMhAREg8KC1RZUEVfU0lOVDY0EBIidAoLQ2Fy",
46             "ZGluYWxpdHkSFwoTQ0FSRElOQUxJVFlfVU5LTk9XThAAEhgKFENBUkRJTkFM",
47             "SVRZX09QVElPTkFMEAESGAoUQ0FSRElOQUxJVFlfUkVRVUlSRUQQAhIYChRD",
48             "QVJESU5BTElUWV9SRVBFQVRFRBADIs4BCgRFbnVtEgwKBG5hbWUYASABKAkS",
49             "LQoJZW51bXZhbHVlGAIgAygLMhouZ29vZ2xlLnByb3RvYnVmLkVudW1WYWx1",
50             "ZRIoCgdvcHRpb25zGAMgAygLMhcuZ29vZ2xlLnByb3RvYnVmLk9wdGlvbhI2",
51             "Cg5zb3VyY2VfY29udGV4dBgEIAEoCzIeLmdvb2dsZS5wcm90b2J1Zi5Tb3Vy",
52             "Y2VDb250ZXh0EicKBnN5bnRheBgFIAEoDjIXLmdvb2dsZS5wcm90b2J1Zi5T",
53             "eW50YXgiUwoJRW51bVZhbHVlEgwKBG5hbWUYASABKAkSDgoGbnVtYmVyGAIg",
54             "ASgFEigKB29wdGlvbnMYAyADKAsyFy5nb29nbGUucHJvdG9idWYuT3B0aW9u",
55             "IjsKBk9wdGlvbhIMCgRuYW1lGAEgASgJEiMKBXZhbHVlGAIgASgLMhQuZ29v",
56             "Z2xlLnByb3RvYnVmLkFueSouCgZTeW50YXgSEQoNU1lOVEFYX1BST1RPMhAA",
57             "EhEKDVNZTlRBWF9QUk9UTzMQAUJMChNjb20uZ29vZ2xlLnByb3RvYnVmQglU",
58             "eXBlUHJvdG9QAaABAaICA0dQQqoCHkdvb2dsZS5Qcm90b2J1Zi5XZWxsS25v",
59             "d25UeXBlc2IGcHJvdG8z"));
60       descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
61           new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.AnyReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.SourceContextReflection.Descriptor, },
62           new pbr::GeneratedClrTypeInfo(new[] {typeof(global::Google.Protobuf.WellKnownTypes.Syntax), }, new pbr::GeneratedClrTypeInfo[] {
63             new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.WellKnownTypes.Type), global::Google.Protobuf.WellKnownTypes.Type.Parser, new[]{ "Name", "Fields", "Oneofs", "Options", "SourceContext", "Syntax" }, null, null, null),
64             new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.WellKnownTypes.Field), global::Google.Protobuf.WellKnownTypes.Field.Parser, new[]{ "Kind", "Cardinality", "Number", "Name", "TypeUrl", "OneofIndex", "Packed", "Options", "JsonName", "DefaultValue" }, null, new[]{ typeof(global::Google.Protobuf.WellKnownTypes.Field.Types.Kind), typeof(global::Google.Protobuf.WellKnownTypes.Field.Types.Cardinality) }, null),
65             new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.WellKnownTypes.Enum), global::Google.Protobuf.WellKnownTypes.Enum.Parser, new[]{ "Name", "Enumvalue", "Options", "SourceContext", "Syntax" }, null, null, null),
66             new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.WellKnownTypes.EnumValue), global::Google.Protobuf.WellKnownTypes.EnumValue.Parser, new[]{ "Name", "Number", "Options" }, null, null, null),
67             new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.WellKnownTypes.Option), global::Google.Protobuf.WellKnownTypes.Option.Parser, new[]{ "Name", "Value" }, null, null, null)
68           }));
69     }
70     #endregion
71 
72   }
73   #region Enums
74   /// <summary>
75   ///  The syntax in which a protocol buffer element is defined.
76   /// </summary>
77   public enum Syntax {
78     /// <summary>
79     ///  Syntax `proto2`.
80     /// </summary>
81     [pbr::OriginalName("SYNTAX_PROTO2")] Proto2 = 0,
82     /// <summary>
83     ///  Syntax `proto3`.
84     /// </summary>
85     [pbr::OriginalName("SYNTAX_PROTO3")] Proto3 = 1,
86   }
87 
88   #endregion
89 
90   #region Messages
91   /// <summary>
92   ///  A protocol buffer message type.
93   /// </summary>
94   public sealed partial class Type : pb::IMessage<Type> {
95     private static readonly pb::MessageParser<Type> _parser = new pb::MessageParser<Type>(() => new Type());
96     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
97     public static pb::MessageParser<Type> Parser { get { return _parser; } }
98 
99     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
100     public static pbr::MessageDescriptor Descriptor {
101       get { return global::Google.Protobuf.WellKnownTypes.TypeReflection.Descriptor.MessageTypes[0]; }
102     }
103 
104     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
105     pbr::MessageDescriptor pb::IMessage.Descriptor {
106       get { return Descriptor; }
107     }
108 
109     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Type()110     public Type() {
111       OnConstruction();
112     }
113 
OnConstruction()114     partial void OnConstruction();
115 
116     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Type(Type other)117     public Type(Type other) : this() {
118       name_ = other.name_;
119       fields_ = other.fields_.Clone();
120       oneofs_ = other.oneofs_.Clone();
121       options_ = other.options_.Clone();
122       SourceContext = other.sourceContext_ != null ? other.SourceContext.Clone() : null;
123       syntax_ = other.syntax_;
124     }
125 
126     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Clone()127     public Type Clone() {
128       return new Type(this);
129     }
130 
131     /// <summary>Field number for the "name" field.</summary>
132     public const int NameFieldNumber = 1;
133     private string name_ = "";
134     /// <summary>
135     ///  The fully qualified message name.
136     /// </summary>
137     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
138     public string Name {
139       get { return name_; }
140       set {
141         name_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
142       }
143     }
144 
145     /// <summary>Field number for the "fields" field.</summary>
146     public const int FieldsFieldNumber = 2;
147     private static readonly pb::FieldCodec<global::Google.Protobuf.WellKnownTypes.Field> _repeated_fields_codec
148         = pb::FieldCodec.ForMessage(18, global::Google.Protobuf.WellKnownTypes.Field.Parser);
149     private readonly pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Field> fields_ = new pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Field>();
150     /// <summary>
151     ///  The list of fields.
152     /// </summary>
153     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
154     public pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Field> Fields {
155       get { return fields_; }
156     }
157 
158     /// <summary>Field number for the "oneofs" field.</summary>
159     public const int OneofsFieldNumber = 3;
160     private static readonly pb::FieldCodec<string> _repeated_oneofs_codec
161         = pb::FieldCodec.ForString(26);
162     private readonly pbc::RepeatedField<string> oneofs_ = new pbc::RepeatedField<string>();
163     /// <summary>
164     ///  The list of types appearing in `oneof` definitions in this type.
165     /// </summary>
166     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
167     public pbc::RepeatedField<string> Oneofs {
168       get { return oneofs_; }
169     }
170 
171     /// <summary>Field number for the "options" field.</summary>
172     public const int OptionsFieldNumber = 4;
173     private static readonly pb::FieldCodec<global::Google.Protobuf.WellKnownTypes.Option> _repeated_options_codec
174         = pb::FieldCodec.ForMessage(34, global::Google.Protobuf.WellKnownTypes.Option.Parser);
175     private readonly pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> options_ = new pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option>();
176     /// <summary>
177     ///  The protocol buffer options.
178     /// </summary>
179     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
180     public pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> Options {
181       get { return options_; }
182     }
183 
184     /// <summary>Field number for the "source_context" field.</summary>
185     public const int SourceContextFieldNumber = 5;
186     private global::Google.Protobuf.WellKnownTypes.SourceContext sourceContext_;
187     /// <summary>
188     ///  The source context.
189     /// </summary>
190     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
191     public global::Google.Protobuf.WellKnownTypes.SourceContext SourceContext {
192       get { return sourceContext_; }
193       set {
194         sourceContext_ = value;
195       }
196     }
197 
198     /// <summary>Field number for the "syntax" field.</summary>
199     public const int SyntaxFieldNumber = 6;
200     private global::Google.Protobuf.WellKnownTypes.Syntax syntax_ = 0;
201     /// <summary>
202     ///  The source syntax.
203     /// </summary>
204     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
205     public global::Google.Protobuf.WellKnownTypes.Syntax Syntax {
206       get { return syntax_; }
207       set {
208         syntax_ = value;
209       }
210     }
211 
212     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(object other)213     public override bool Equals(object other) {
214       return Equals(other as Type);
215     }
216 
217     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(Type other)218     public bool Equals(Type other) {
219       if (ReferenceEquals(other, null)) {
220         return false;
221       }
222       if (ReferenceEquals(other, this)) {
223         return true;
224       }
225       if (Name != other.Name) return false;
226       if(!fields_.Equals(other.fields_)) return false;
227       if(!oneofs_.Equals(other.oneofs_)) return false;
228       if(!options_.Equals(other.options_)) return false;
229       if (!object.Equals(SourceContext, other.SourceContext)) return false;
230       if (Syntax != other.Syntax) return false;
231       return true;
232     }
233 
234     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
GetHashCode()235     public override int GetHashCode() {
236       int hash = 1;
237       if (Name.Length != 0) hash ^= Name.GetHashCode();
238       hash ^= fields_.GetHashCode();
239       hash ^= oneofs_.GetHashCode();
240       hash ^= options_.GetHashCode();
241       if (sourceContext_ != null) hash ^= SourceContext.GetHashCode();
242       if (Syntax != 0) hash ^= Syntax.GetHashCode();
243       return hash;
244     }
245 
246     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
ToString()247     public override string ToString() {
248       return pb::JsonFormatter.ToDiagnosticString(this);
249     }
250 
251     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
WriteTo(pb::CodedOutputStream output)252     public void WriteTo(pb::CodedOutputStream output) {
253       if (Name.Length != 0) {
254         output.WriteRawTag(10);
255         output.WriteString(Name);
256       }
257       fields_.WriteTo(output, _repeated_fields_codec);
258       oneofs_.WriteTo(output, _repeated_oneofs_codec);
259       options_.WriteTo(output, _repeated_options_codec);
260       if (sourceContext_ != null) {
261         output.WriteRawTag(42);
262         output.WriteMessage(SourceContext);
263       }
264       if (Syntax != 0) {
265         output.WriteRawTag(48);
266         output.WriteEnum((int) Syntax);
267       }
268     }
269 
270     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
CalculateSize()271     public int CalculateSize() {
272       int size = 0;
273       if (Name.Length != 0) {
274         size += 1 + pb::CodedOutputStream.ComputeStringSize(Name);
275       }
276       size += fields_.CalculateSize(_repeated_fields_codec);
277       size += oneofs_.CalculateSize(_repeated_oneofs_codec);
278       size += options_.CalculateSize(_repeated_options_codec);
279       if (sourceContext_ != null) {
280         size += 1 + pb::CodedOutputStream.ComputeMessageSize(SourceContext);
281       }
282       if (Syntax != 0) {
283         size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Syntax);
284       }
285       return size;
286     }
287 
288     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(Type other)289     public void MergeFrom(Type other) {
290       if (other == null) {
291         return;
292       }
293       if (other.Name.Length != 0) {
294         Name = other.Name;
295       }
296       fields_.Add(other.fields_);
297       oneofs_.Add(other.oneofs_);
298       options_.Add(other.options_);
299       if (other.sourceContext_ != null) {
300         if (sourceContext_ == null) {
301           sourceContext_ = new global::Google.Protobuf.WellKnownTypes.SourceContext();
302         }
303         SourceContext.MergeFrom(other.SourceContext);
304       }
305       if (other.Syntax != 0) {
306         Syntax = other.Syntax;
307       }
308     }
309 
310     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(pb::CodedInputStream input)311     public void MergeFrom(pb::CodedInputStream input) {
312       uint tag;
313       while ((tag = input.ReadTag()) != 0) {
314         switch(tag) {
315           default:
316             input.SkipLastField();
317             break;
318           case 10: {
319             Name = input.ReadString();
320             break;
321           }
322           case 18: {
323             fields_.AddEntriesFrom(input, _repeated_fields_codec);
324             break;
325           }
326           case 26: {
327             oneofs_.AddEntriesFrom(input, _repeated_oneofs_codec);
328             break;
329           }
330           case 34: {
331             options_.AddEntriesFrom(input, _repeated_options_codec);
332             break;
333           }
334           case 42: {
335             if (sourceContext_ == null) {
336               sourceContext_ = new global::Google.Protobuf.WellKnownTypes.SourceContext();
337             }
338             input.ReadMessage(sourceContext_);
339             break;
340           }
341           case 48: {
342             syntax_ = (global::Google.Protobuf.WellKnownTypes.Syntax) input.ReadEnum();
343             break;
344           }
345         }
346       }
347     }
348 
349   }
350 
351   /// <summary>
352   ///  A single field of a message type.
353   /// </summary>
354   public sealed partial class Field : pb::IMessage<Field> {
355     private static readonly pb::MessageParser<Field> _parser = new pb::MessageParser<Field>(() => new Field());
356     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
357     public static pb::MessageParser<Field> Parser { get { return _parser; } }
358 
359     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
360     public static pbr::MessageDescriptor Descriptor {
361       get { return global::Google.Protobuf.WellKnownTypes.TypeReflection.Descriptor.MessageTypes[1]; }
362     }
363 
364     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
365     pbr::MessageDescriptor pb::IMessage.Descriptor {
366       get { return Descriptor; }
367     }
368 
369     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Field()370     public Field() {
371       OnConstruction();
372     }
373 
OnConstruction()374     partial void OnConstruction();
375 
376     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Field(Field other)377     public Field(Field other) : this() {
378       kind_ = other.kind_;
379       cardinality_ = other.cardinality_;
380       number_ = other.number_;
381       name_ = other.name_;
382       typeUrl_ = other.typeUrl_;
383       oneofIndex_ = other.oneofIndex_;
384       packed_ = other.packed_;
385       options_ = other.options_.Clone();
386       jsonName_ = other.jsonName_;
387       defaultValue_ = other.defaultValue_;
388     }
389 
390     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Clone()391     public Field Clone() {
392       return new Field(this);
393     }
394 
395     /// <summary>Field number for the "kind" field.</summary>
396     public const int KindFieldNumber = 1;
397     private global::Google.Protobuf.WellKnownTypes.Field.Types.Kind kind_ = 0;
398     /// <summary>
399     ///  The field type.
400     /// </summary>
401     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
402     public global::Google.Protobuf.WellKnownTypes.Field.Types.Kind Kind {
403       get { return kind_; }
404       set {
405         kind_ = value;
406       }
407     }
408 
409     /// <summary>Field number for the "cardinality" field.</summary>
410     public const int CardinalityFieldNumber = 2;
411     private global::Google.Protobuf.WellKnownTypes.Field.Types.Cardinality cardinality_ = 0;
412     /// <summary>
413     ///  The field cardinality.
414     /// </summary>
415     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
416     public global::Google.Protobuf.WellKnownTypes.Field.Types.Cardinality Cardinality {
417       get { return cardinality_; }
418       set {
419         cardinality_ = value;
420       }
421     }
422 
423     /// <summary>Field number for the "number" field.</summary>
424     public const int NumberFieldNumber = 3;
425     private int number_;
426     /// <summary>
427     ///  The field number.
428     /// </summary>
429     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
430     public int Number {
431       get { return number_; }
432       set {
433         number_ = value;
434       }
435     }
436 
437     /// <summary>Field number for the "name" field.</summary>
438     public const int NameFieldNumber = 4;
439     private string name_ = "";
440     /// <summary>
441     ///  The field name.
442     /// </summary>
443     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
444     public string Name {
445       get { return name_; }
446       set {
447         name_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
448       }
449     }
450 
451     /// <summary>Field number for the "type_url" field.</summary>
452     public const int TypeUrlFieldNumber = 6;
453     private string typeUrl_ = "";
454     /// <summary>
455     ///  The field type URL, without the scheme, for message or enumeration
456     ///  types. Example: `"type.googleapis.com/google.protobuf.Timestamp"`.
457     /// </summary>
458     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
459     public string TypeUrl {
460       get { return typeUrl_; }
461       set {
462         typeUrl_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
463       }
464     }
465 
466     /// <summary>Field number for the "oneof_index" field.</summary>
467     public const int OneofIndexFieldNumber = 7;
468     private int oneofIndex_;
469     /// <summary>
470     ///  The index of the field type in `Type.oneofs`, for message or enumeration
471     ///  types. The first type has index 1; zero means the type is not in the list.
472     /// </summary>
473     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
474     public int OneofIndex {
475       get { return oneofIndex_; }
476       set {
477         oneofIndex_ = value;
478       }
479     }
480 
481     /// <summary>Field number for the "packed" field.</summary>
482     public const int PackedFieldNumber = 8;
483     private bool packed_;
484     /// <summary>
485     ///  Whether to use alternative packed wire representation.
486     /// </summary>
487     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
488     public bool Packed {
489       get { return packed_; }
490       set {
491         packed_ = value;
492       }
493     }
494 
495     /// <summary>Field number for the "options" field.</summary>
496     public const int OptionsFieldNumber = 9;
497     private static readonly pb::FieldCodec<global::Google.Protobuf.WellKnownTypes.Option> _repeated_options_codec
498         = pb::FieldCodec.ForMessage(74, global::Google.Protobuf.WellKnownTypes.Option.Parser);
499     private readonly pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> options_ = new pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option>();
500     /// <summary>
501     ///  The protocol buffer options.
502     /// </summary>
503     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
504     public pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> Options {
505       get { return options_; }
506     }
507 
508     /// <summary>Field number for the "json_name" field.</summary>
509     public const int JsonNameFieldNumber = 10;
510     private string jsonName_ = "";
511     /// <summary>
512     ///  The field JSON name.
513     /// </summary>
514     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
515     public string JsonName {
516       get { return jsonName_; }
517       set {
518         jsonName_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
519       }
520     }
521 
522     /// <summary>Field number for the "default_value" field.</summary>
523     public const int DefaultValueFieldNumber = 11;
524     private string defaultValue_ = "";
525     /// <summary>
526     ///  The string value of the default value of this field. Proto2 syntax only.
527     /// </summary>
528     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
529     public string DefaultValue {
530       get { return defaultValue_; }
531       set {
532         defaultValue_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
533       }
534     }
535 
536     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(object other)537     public override bool Equals(object other) {
538       return Equals(other as Field);
539     }
540 
541     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(Field other)542     public bool Equals(Field other) {
543       if (ReferenceEquals(other, null)) {
544         return false;
545       }
546       if (ReferenceEquals(other, this)) {
547         return true;
548       }
549       if (Kind != other.Kind) return false;
550       if (Cardinality != other.Cardinality) return false;
551       if (Number != other.Number) return false;
552       if (Name != other.Name) return false;
553       if (TypeUrl != other.TypeUrl) return false;
554       if (OneofIndex != other.OneofIndex) return false;
555       if (Packed != other.Packed) return false;
556       if(!options_.Equals(other.options_)) return false;
557       if (JsonName != other.JsonName) return false;
558       if (DefaultValue != other.DefaultValue) return false;
559       return true;
560     }
561 
562     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
GetHashCode()563     public override int GetHashCode() {
564       int hash = 1;
565       if (Kind != 0) hash ^= Kind.GetHashCode();
566       if (Cardinality != 0) hash ^= Cardinality.GetHashCode();
567       if (Number != 0) hash ^= Number.GetHashCode();
568       if (Name.Length != 0) hash ^= Name.GetHashCode();
569       if (TypeUrl.Length != 0) hash ^= TypeUrl.GetHashCode();
570       if (OneofIndex != 0) hash ^= OneofIndex.GetHashCode();
571       if (Packed != false) hash ^= Packed.GetHashCode();
572       hash ^= options_.GetHashCode();
573       if (JsonName.Length != 0) hash ^= JsonName.GetHashCode();
574       if (DefaultValue.Length != 0) hash ^= DefaultValue.GetHashCode();
575       return hash;
576     }
577 
578     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
ToString()579     public override string ToString() {
580       return pb::JsonFormatter.ToDiagnosticString(this);
581     }
582 
583     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
WriteTo(pb::CodedOutputStream output)584     public void WriteTo(pb::CodedOutputStream output) {
585       if (Kind != 0) {
586         output.WriteRawTag(8);
587         output.WriteEnum((int) Kind);
588       }
589       if (Cardinality != 0) {
590         output.WriteRawTag(16);
591         output.WriteEnum((int) Cardinality);
592       }
593       if (Number != 0) {
594         output.WriteRawTag(24);
595         output.WriteInt32(Number);
596       }
597       if (Name.Length != 0) {
598         output.WriteRawTag(34);
599         output.WriteString(Name);
600       }
601       if (TypeUrl.Length != 0) {
602         output.WriteRawTag(50);
603         output.WriteString(TypeUrl);
604       }
605       if (OneofIndex != 0) {
606         output.WriteRawTag(56);
607         output.WriteInt32(OneofIndex);
608       }
609       if (Packed != false) {
610         output.WriteRawTag(64);
611         output.WriteBool(Packed);
612       }
613       options_.WriteTo(output, _repeated_options_codec);
614       if (JsonName.Length != 0) {
615         output.WriteRawTag(82);
616         output.WriteString(JsonName);
617       }
618       if (DefaultValue.Length != 0) {
619         output.WriteRawTag(90);
620         output.WriteString(DefaultValue);
621       }
622     }
623 
624     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
CalculateSize()625     public int CalculateSize() {
626       int size = 0;
627       if (Kind != 0) {
628         size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Kind);
629       }
630       if (Cardinality != 0) {
631         size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Cardinality);
632       }
633       if (Number != 0) {
634         size += 1 + pb::CodedOutputStream.ComputeInt32Size(Number);
635       }
636       if (Name.Length != 0) {
637         size += 1 + pb::CodedOutputStream.ComputeStringSize(Name);
638       }
639       if (TypeUrl.Length != 0) {
640         size += 1 + pb::CodedOutputStream.ComputeStringSize(TypeUrl);
641       }
642       if (OneofIndex != 0) {
643         size += 1 + pb::CodedOutputStream.ComputeInt32Size(OneofIndex);
644       }
645       if (Packed != false) {
646         size += 1 + 1;
647       }
648       size += options_.CalculateSize(_repeated_options_codec);
649       if (JsonName.Length != 0) {
650         size += 1 + pb::CodedOutputStream.ComputeStringSize(JsonName);
651       }
652       if (DefaultValue.Length != 0) {
653         size += 1 + pb::CodedOutputStream.ComputeStringSize(DefaultValue);
654       }
655       return size;
656     }
657 
658     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(Field other)659     public void MergeFrom(Field other) {
660       if (other == null) {
661         return;
662       }
663       if (other.Kind != 0) {
664         Kind = other.Kind;
665       }
666       if (other.Cardinality != 0) {
667         Cardinality = other.Cardinality;
668       }
669       if (other.Number != 0) {
670         Number = other.Number;
671       }
672       if (other.Name.Length != 0) {
673         Name = other.Name;
674       }
675       if (other.TypeUrl.Length != 0) {
676         TypeUrl = other.TypeUrl;
677       }
678       if (other.OneofIndex != 0) {
679         OneofIndex = other.OneofIndex;
680       }
681       if (other.Packed != false) {
682         Packed = other.Packed;
683       }
684       options_.Add(other.options_);
685       if (other.JsonName.Length != 0) {
686         JsonName = other.JsonName;
687       }
688       if (other.DefaultValue.Length != 0) {
689         DefaultValue = other.DefaultValue;
690       }
691     }
692 
693     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(pb::CodedInputStream input)694     public void MergeFrom(pb::CodedInputStream input) {
695       uint tag;
696       while ((tag = input.ReadTag()) != 0) {
697         switch(tag) {
698           default:
699             input.SkipLastField();
700             break;
701           case 8: {
702             kind_ = (global::Google.Protobuf.WellKnownTypes.Field.Types.Kind) input.ReadEnum();
703             break;
704           }
705           case 16: {
706             cardinality_ = (global::Google.Protobuf.WellKnownTypes.Field.Types.Cardinality) input.ReadEnum();
707             break;
708           }
709           case 24: {
710             Number = input.ReadInt32();
711             break;
712           }
713           case 34: {
714             Name = input.ReadString();
715             break;
716           }
717           case 50: {
718             TypeUrl = input.ReadString();
719             break;
720           }
721           case 56: {
722             OneofIndex = input.ReadInt32();
723             break;
724           }
725           case 64: {
726             Packed = input.ReadBool();
727             break;
728           }
729           case 74: {
730             options_.AddEntriesFrom(input, _repeated_options_codec);
731             break;
732           }
733           case 82: {
734             JsonName = input.ReadString();
735             break;
736           }
737           case 90: {
738             DefaultValue = input.ReadString();
739             break;
740           }
741         }
742       }
743     }
744 
745     #region Nested types
746     /// <summary>Container for nested types declared in the Field message type.</summary>
747     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
748     public static partial class Types {
749       /// <summary>
750       ///  Basic field types.
751       /// </summary>
752       public enum Kind {
753         /// <summary>
754         ///  Field type unknown.
755         /// </summary>
756         [pbr::OriginalName("TYPE_UNKNOWN")] TypeUnknown = 0,
757         /// <summary>
758         ///  Field type double.
759         /// </summary>
760         [pbr::OriginalName("TYPE_DOUBLE")] TypeDouble = 1,
761         /// <summary>
762         ///  Field type float.
763         /// </summary>
764         [pbr::OriginalName("TYPE_FLOAT")] TypeFloat = 2,
765         /// <summary>
766         ///  Field type int64.
767         /// </summary>
768         [pbr::OriginalName("TYPE_INT64")] TypeInt64 = 3,
769         /// <summary>
770         ///  Field type uint64.
771         /// </summary>
772         [pbr::OriginalName("TYPE_UINT64")] TypeUint64 = 4,
773         /// <summary>
774         ///  Field type int32.
775         /// </summary>
776         [pbr::OriginalName("TYPE_INT32")] TypeInt32 = 5,
777         /// <summary>
778         ///  Field type fixed64.
779         /// </summary>
780         [pbr::OriginalName("TYPE_FIXED64")] TypeFixed64 = 6,
781         /// <summary>
782         ///  Field type fixed32.
783         /// </summary>
784         [pbr::OriginalName("TYPE_FIXED32")] TypeFixed32 = 7,
785         /// <summary>
786         ///  Field type bool.
787         /// </summary>
788         [pbr::OriginalName("TYPE_BOOL")] TypeBool = 8,
789         /// <summary>
790         ///  Field type string.
791         /// </summary>
792         [pbr::OriginalName("TYPE_STRING")] TypeString = 9,
793         /// <summary>
794         ///  Field type group. Proto2 syntax only, and deprecated.
795         /// </summary>
796         [pbr::OriginalName("TYPE_GROUP")] TypeGroup = 10,
797         /// <summary>
798         ///  Field type message.
799         /// </summary>
800         [pbr::OriginalName("TYPE_MESSAGE")] TypeMessage = 11,
801         /// <summary>
802         ///  Field type bytes.
803         /// </summary>
804         [pbr::OriginalName("TYPE_BYTES")] TypeBytes = 12,
805         /// <summary>
806         ///  Field type uint32.
807         /// </summary>
808         [pbr::OriginalName("TYPE_UINT32")] TypeUint32 = 13,
809         /// <summary>
810         ///  Field type enum.
811         /// </summary>
812         [pbr::OriginalName("TYPE_ENUM")] TypeEnum = 14,
813         /// <summary>
814         ///  Field type sfixed32.
815         /// </summary>
816         [pbr::OriginalName("TYPE_SFIXED32")] TypeSfixed32 = 15,
817         /// <summary>
818         ///  Field type sfixed64.
819         /// </summary>
820         [pbr::OriginalName("TYPE_SFIXED64")] TypeSfixed64 = 16,
821         /// <summary>
822         ///  Field type sint32.
823         /// </summary>
824         [pbr::OriginalName("TYPE_SINT32")] TypeSint32 = 17,
825         /// <summary>
826         ///  Field type sint64.
827         /// </summary>
828         [pbr::OriginalName("TYPE_SINT64")] TypeSint64 = 18,
829       }
830 
831       /// <summary>
832       ///  Whether a field is optional, required, or repeated.
833       /// </summary>
834       public enum Cardinality {
835         /// <summary>
836         ///  For fields with unknown cardinality.
837         /// </summary>
838         [pbr::OriginalName("CARDINALITY_UNKNOWN")] Unknown = 0,
839         /// <summary>
840         ///  For optional fields.
841         /// </summary>
842         [pbr::OriginalName("CARDINALITY_OPTIONAL")] Optional = 1,
843         /// <summary>
844         ///  For required fields. Proto2 syntax only.
845         /// </summary>
846         [pbr::OriginalName("CARDINALITY_REQUIRED")] Required = 2,
847         /// <summary>
848         ///  For repeated fields.
849         /// </summary>
850         [pbr::OriginalName("CARDINALITY_REPEATED")] Repeated = 3,
851       }
852 
853     }
854     #endregion
855 
856   }
857 
858   /// <summary>
859   ///  Enum type definition.
860   /// </summary>
861   public sealed partial class Enum : pb::IMessage<Enum> {
862     private static readonly pb::MessageParser<Enum> _parser = new pb::MessageParser<Enum>(() => new Enum());
863     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
864     public static pb::MessageParser<Enum> Parser { get { return _parser; } }
865 
866     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
867     public static pbr::MessageDescriptor Descriptor {
868       get { return global::Google.Protobuf.WellKnownTypes.TypeReflection.Descriptor.MessageTypes[2]; }
869     }
870 
871     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
872     pbr::MessageDescriptor pb::IMessage.Descriptor {
873       get { return Descriptor; }
874     }
875 
876     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Enum()877     public Enum() {
878       OnConstruction();
879     }
880 
OnConstruction()881     partial void OnConstruction();
882 
883     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Enum(Enum other)884     public Enum(Enum other) : this() {
885       name_ = other.name_;
886       enumvalue_ = other.enumvalue_.Clone();
887       options_ = other.options_.Clone();
888       SourceContext = other.sourceContext_ != null ? other.SourceContext.Clone() : null;
889       syntax_ = other.syntax_;
890     }
891 
892     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Clone()893     public Enum Clone() {
894       return new Enum(this);
895     }
896 
897     /// <summary>Field number for the "name" field.</summary>
898     public const int NameFieldNumber = 1;
899     private string name_ = "";
900     /// <summary>
901     ///  Enum type name.
902     /// </summary>
903     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
904     public string Name {
905       get { return name_; }
906       set {
907         name_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
908       }
909     }
910 
911     /// <summary>Field number for the "enumvalue" field.</summary>
912     public const int EnumvalueFieldNumber = 2;
913     private static readonly pb::FieldCodec<global::Google.Protobuf.WellKnownTypes.EnumValue> _repeated_enumvalue_codec
914         = pb::FieldCodec.ForMessage(18, global::Google.Protobuf.WellKnownTypes.EnumValue.Parser);
915     private readonly pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.EnumValue> enumvalue_ = new pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.EnumValue>();
916     /// <summary>
917     ///  Enum value definitions.
918     /// </summary>
919     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
920     public pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.EnumValue> Enumvalue {
921       get { return enumvalue_; }
922     }
923 
924     /// <summary>Field number for the "options" field.</summary>
925     public const int OptionsFieldNumber = 3;
926     private static readonly pb::FieldCodec<global::Google.Protobuf.WellKnownTypes.Option> _repeated_options_codec
927         = pb::FieldCodec.ForMessage(26, global::Google.Protobuf.WellKnownTypes.Option.Parser);
928     private readonly pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> options_ = new pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option>();
929     /// <summary>
930     ///  Protocol buffer options.
931     /// </summary>
932     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
933     public pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> Options {
934       get { return options_; }
935     }
936 
937     /// <summary>Field number for the "source_context" field.</summary>
938     public const int SourceContextFieldNumber = 4;
939     private global::Google.Protobuf.WellKnownTypes.SourceContext sourceContext_;
940     /// <summary>
941     ///  The source context.
942     /// </summary>
943     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
944     public global::Google.Protobuf.WellKnownTypes.SourceContext SourceContext {
945       get { return sourceContext_; }
946       set {
947         sourceContext_ = value;
948       }
949     }
950 
951     /// <summary>Field number for the "syntax" field.</summary>
952     public const int SyntaxFieldNumber = 5;
953     private global::Google.Protobuf.WellKnownTypes.Syntax syntax_ = 0;
954     /// <summary>
955     ///  The source syntax.
956     /// </summary>
957     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
958     public global::Google.Protobuf.WellKnownTypes.Syntax Syntax {
959       get { return syntax_; }
960       set {
961         syntax_ = value;
962       }
963     }
964 
965     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(object other)966     public override bool Equals(object other) {
967       return Equals(other as Enum);
968     }
969 
970     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(Enum other)971     public bool Equals(Enum other) {
972       if (ReferenceEquals(other, null)) {
973         return false;
974       }
975       if (ReferenceEquals(other, this)) {
976         return true;
977       }
978       if (Name != other.Name) return false;
979       if(!enumvalue_.Equals(other.enumvalue_)) return false;
980       if(!options_.Equals(other.options_)) return false;
981       if (!object.Equals(SourceContext, other.SourceContext)) return false;
982       if (Syntax != other.Syntax) return false;
983       return true;
984     }
985 
986     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
GetHashCode()987     public override int GetHashCode() {
988       int hash = 1;
989       if (Name.Length != 0) hash ^= Name.GetHashCode();
990       hash ^= enumvalue_.GetHashCode();
991       hash ^= options_.GetHashCode();
992       if (sourceContext_ != null) hash ^= SourceContext.GetHashCode();
993       if (Syntax != 0) hash ^= Syntax.GetHashCode();
994       return hash;
995     }
996 
997     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
ToString()998     public override string ToString() {
999       return pb::JsonFormatter.ToDiagnosticString(this);
1000     }
1001 
1002     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
WriteTo(pb::CodedOutputStream output)1003     public void WriteTo(pb::CodedOutputStream output) {
1004       if (Name.Length != 0) {
1005         output.WriteRawTag(10);
1006         output.WriteString(Name);
1007       }
1008       enumvalue_.WriteTo(output, _repeated_enumvalue_codec);
1009       options_.WriteTo(output, _repeated_options_codec);
1010       if (sourceContext_ != null) {
1011         output.WriteRawTag(34);
1012         output.WriteMessage(SourceContext);
1013       }
1014       if (Syntax != 0) {
1015         output.WriteRawTag(40);
1016         output.WriteEnum((int) Syntax);
1017       }
1018     }
1019 
1020     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
CalculateSize()1021     public int CalculateSize() {
1022       int size = 0;
1023       if (Name.Length != 0) {
1024         size += 1 + pb::CodedOutputStream.ComputeStringSize(Name);
1025       }
1026       size += enumvalue_.CalculateSize(_repeated_enumvalue_codec);
1027       size += options_.CalculateSize(_repeated_options_codec);
1028       if (sourceContext_ != null) {
1029         size += 1 + pb::CodedOutputStream.ComputeMessageSize(SourceContext);
1030       }
1031       if (Syntax != 0) {
1032         size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Syntax);
1033       }
1034       return size;
1035     }
1036 
1037     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(Enum other)1038     public void MergeFrom(Enum other) {
1039       if (other == null) {
1040         return;
1041       }
1042       if (other.Name.Length != 0) {
1043         Name = other.Name;
1044       }
1045       enumvalue_.Add(other.enumvalue_);
1046       options_.Add(other.options_);
1047       if (other.sourceContext_ != null) {
1048         if (sourceContext_ == null) {
1049           sourceContext_ = new global::Google.Protobuf.WellKnownTypes.SourceContext();
1050         }
1051         SourceContext.MergeFrom(other.SourceContext);
1052       }
1053       if (other.Syntax != 0) {
1054         Syntax = other.Syntax;
1055       }
1056     }
1057 
1058     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(pb::CodedInputStream input)1059     public void MergeFrom(pb::CodedInputStream input) {
1060       uint tag;
1061       while ((tag = input.ReadTag()) != 0) {
1062         switch(tag) {
1063           default:
1064             input.SkipLastField();
1065             break;
1066           case 10: {
1067             Name = input.ReadString();
1068             break;
1069           }
1070           case 18: {
1071             enumvalue_.AddEntriesFrom(input, _repeated_enumvalue_codec);
1072             break;
1073           }
1074           case 26: {
1075             options_.AddEntriesFrom(input, _repeated_options_codec);
1076             break;
1077           }
1078           case 34: {
1079             if (sourceContext_ == null) {
1080               sourceContext_ = new global::Google.Protobuf.WellKnownTypes.SourceContext();
1081             }
1082             input.ReadMessage(sourceContext_);
1083             break;
1084           }
1085           case 40: {
1086             syntax_ = (global::Google.Protobuf.WellKnownTypes.Syntax) input.ReadEnum();
1087             break;
1088           }
1089         }
1090       }
1091     }
1092 
1093   }
1094 
1095   /// <summary>
1096   ///  Enum value definition.
1097   /// </summary>
1098   public sealed partial class EnumValue : pb::IMessage<EnumValue> {
1099     private static readonly pb::MessageParser<EnumValue> _parser = new pb::MessageParser<EnumValue>(() => new EnumValue());
1100     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1101     public static pb::MessageParser<EnumValue> Parser { get { return _parser; } }
1102 
1103     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1104     public static pbr::MessageDescriptor Descriptor {
1105       get { return global::Google.Protobuf.WellKnownTypes.TypeReflection.Descriptor.MessageTypes[3]; }
1106     }
1107 
1108     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1109     pbr::MessageDescriptor pb::IMessage.Descriptor {
1110       get { return Descriptor; }
1111     }
1112 
1113     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
EnumValue()1114     public EnumValue() {
1115       OnConstruction();
1116     }
1117 
OnConstruction()1118     partial void OnConstruction();
1119 
1120     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
EnumValue(EnumValue other)1121     public EnumValue(EnumValue other) : this() {
1122       name_ = other.name_;
1123       number_ = other.number_;
1124       options_ = other.options_.Clone();
1125     }
1126 
1127     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Clone()1128     public EnumValue Clone() {
1129       return new EnumValue(this);
1130     }
1131 
1132     /// <summary>Field number for the "name" field.</summary>
1133     public const int NameFieldNumber = 1;
1134     private string name_ = "";
1135     /// <summary>
1136     ///  Enum value name.
1137     /// </summary>
1138     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1139     public string Name {
1140       get { return name_; }
1141       set {
1142         name_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
1143       }
1144     }
1145 
1146     /// <summary>Field number for the "number" field.</summary>
1147     public const int NumberFieldNumber = 2;
1148     private int number_;
1149     /// <summary>
1150     ///  Enum value number.
1151     /// </summary>
1152     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1153     public int Number {
1154       get { return number_; }
1155       set {
1156         number_ = value;
1157       }
1158     }
1159 
1160     /// <summary>Field number for the "options" field.</summary>
1161     public const int OptionsFieldNumber = 3;
1162     private static readonly pb::FieldCodec<global::Google.Protobuf.WellKnownTypes.Option> _repeated_options_codec
1163         = pb::FieldCodec.ForMessage(26, global::Google.Protobuf.WellKnownTypes.Option.Parser);
1164     private readonly pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> options_ = new pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option>();
1165     /// <summary>
1166     ///  Protocol buffer options.
1167     /// </summary>
1168     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1169     public pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Option> Options {
1170       get { return options_; }
1171     }
1172 
1173     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(object other)1174     public override bool Equals(object other) {
1175       return Equals(other as EnumValue);
1176     }
1177 
1178     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(EnumValue other)1179     public bool Equals(EnumValue other) {
1180       if (ReferenceEquals(other, null)) {
1181         return false;
1182       }
1183       if (ReferenceEquals(other, this)) {
1184         return true;
1185       }
1186       if (Name != other.Name) return false;
1187       if (Number != other.Number) return false;
1188       if(!options_.Equals(other.options_)) return false;
1189       return true;
1190     }
1191 
1192     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
GetHashCode()1193     public override int GetHashCode() {
1194       int hash = 1;
1195       if (Name.Length != 0) hash ^= Name.GetHashCode();
1196       if (Number != 0) hash ^= Number.GetHashCode();
1197       hash ^= options_.GetHashCode();
1198       return hash;
1199     }
1200 
1201     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
ToString()1202     public override string ToString() {
1203       return pb::JsonFormatter.ToDiagnosticString(this);
1204     }
1205 
1206     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
WriteTo(pb::CodedOutputStream output)1207     public void WriteTo(pb::CodedOutputStream output) {
1208       if (Name.Length != 0) {
1209         output.WriteRawTag(10);
1210         output.WriteString(Name);
1211       }
1212       if (Number != 0) {
1213         output.WriteRawTag(16);
1214         output.WriteInt32(Number);
1215       }
1216       options_.WriteTo(output, _repeated_options_codec);
1217     }
1218 
1219     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
CalculateSize()1220     public int CalculateSize() {
1221       int size = 0;
1222       if (Name.Length != 0) {
1223         size += 1 + pb::CodedOutputStream.ComputeStringSize(Name);
1224       }
1225       if (Number != 0) {
1226         size += 1 + pb::CodedOutputStream.ComputeInt32Size(Number);
1227       }
1228       size += options_.CalculateSize(_repeated_options_codec);
1229       return size;
1230     }
1231 
1232     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(EnumValue other)1233     public void MergeFrom(EnumValue other) {
1234       if (other == null) {
1235         return;
1236       }
1237       if (other.Name.Length != 0) {
1238         Name = other.Name;
1239       }
1240       if (other.Number != 0) {
1241         Number = other.Number;
1242       }
1243       options_.Add(other.options_);
1244     }
1245 
1246     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(pb::CodedInputStream input)1247     public void MergeFrom(pb::CodedInputStream input) {
1248       uint tag;
1249       while ((tag = input.ReadTag()) != 0) {
1250         switch(tag) {
1251           default:
1252             input.SkipLastField();
1253             break;
1254           case 10: {
1255             Name = input.ReadString();
1256             break;
1257           }
1258           case 16: {
1259             Number = input.ReadInt32();
1260             break;
1261           }
1262           case 26: {
1263             options_.AddEntriesFrom(input, _repeated_options_codec);
1264             break;
1265           }
1266         }
1267       }
1268     }
1269 
1270   }
1271 
1272   /// <summary>
1273   ///  A protocol buffer option, which can be attached to a message, field,
1274   ///  enumeration, etc.
1275   /// </summary>
1276   public sealed partial class Option : pb::IMessage<Option> {
1277     private static readonly pb::MessageParser<Option> _parser = new pb::MessageParser<Option>(() => new Option());
1278     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1279     public static pb::MessageParser<Option> Parser { get { return _parser; } }
1280 
1281     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1282     public static pbr::MessageDescriptor Descriptor {
1283       get { return global::Google.Protobuf.WellKnownTypes.TypeReflection.Descriptor.MessageTypes[4]; }
1284     }
1285 
1286     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1287     pbr::MessageDescriptor pb::IMessage.Descriptor {
1288       get { return Descriptor; }
1289     }
1290 
1291     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Option()1292     public Option() {
1293       OnConstruction();
1294     }
1295 
OnConstruction()1296     partial void OnConstruction();
1297 
1298     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Option(Option other)1299     public Option(Option other) : this() {
1300       name_ = other.name_;
1301       Value = other.value_ != null ? other.Value.Clone() : null;
1302     }
1303 
1304     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Clone()1305     public Option Clone() {
1306       return new Option(this);
1307     }
1308 
1309     /// <summary>Field number for the "name" field.</summary>
1310     public const int NameFieldNumber = 1;
1311     private string name_ = "";
1312     /// <summary>
1313     ///  The option's name. For example, `"java_package"`.
1314     /// </summary>
1315     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1316     public string Name {
1317       get { return name_; }
1318       set {
1319         name_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
1320       }
1321     }
1322 
1323     /// <summary>Field number for the "value" field.</summary>
1324     public const int ValueFieldNumber = 2;
1325     private global::Google.Protobuf.WellKnownTypes.Any value_;
1326     /// <summary>
1327     ///  The option's value. For example, `"com.google.protobuf"`.
1328     /// </summary>
1329     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
1330     public global::Google.Protobuf.WellKnownTypes.Any Value {
1331       get { return value_; }
1332       set {
1333         value_ = value;
1334       }
1335     }
1336 
1337     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(object other)1338     public override bool Equals(object other) {
1339       return Equals(other as Option);
1340     }
1341 
1342     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
Equals(Option other)1343     public bool Equals(Option other) {
1344       if (ReferenceEquals(other, null)) {
1345         return false;
1346       }
1347       if (ReferenceEquals(other, this)) {
1348         return true;
1349       }
1350       if (Name != other.Name) return false;
1351       if (!object.Equals(Value, other.Value)) return false;
1352       return true;
1353     }
1354 
1355     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
GetHashCode()1356     public override int GetHashCode() {
1357       int hash = 1;
1358       if (Name.Length != 0) hash ^= Name.GetHashCode();
1359       if (value_ != null) hash ^= Value.GetHashCode();
1360       return hash;
1361     }
1362 
1363     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
ToString()1364     public override string ToString() {
1365       return pb::JsonFormatter.ToDiagnosticString(this);
1366     }
1367 
1368     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
WriteTo(pb::CodedOutputStream output)1369     public void WriteTo(pb::CodedOutputStream output) {
1370       if (Name.Length != 0) {
1371         output.WriteRawTag(10);
1372         output.WriteString(Name);
1373       }
1374       if (value_ != null) {
1375         output.WriteRawTag(18);
1376         output.WriteMessage(Value);
1377       }
1378     }
1379 
1380     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
CalculateSize()1381     public int CalculateSize() {
1382       int size = 0;
1383       if (Name.Length != 0) {
1384         size += 1 + pb::CodedOutputStream.ComputeStringSize(Name);
1385       }
1386       if (value_ != null) {
1387         size += 1 + pb::CodedOutputStream.ComputeMessageSize(Value);
1388       }
1389       return size;
1390     }
1391 
1392     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(Option other)1393     public void MergeFrom(Option other) {
1394       if (other == null) {
1395         return;
1396       }
1397       if (other.Name.Length != 0) {
1398         Name = other.Name;
1399       }
1400       if (other.value_ != null) {
1401         if (value_ == null) {
1402           value_ = new global::Google.Protobuf.WellKnownTypes.Any();
1403         }
1404         Value.MergeFrom(other.Value);
1405       }
1406     }
1407 
1408     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
MergeFrom(pb::CodedInputStream input)1409     public void MergeFrom(pb::CodedInputStream input) {
1410       uint tag;
1411       while ((tag = input.ReadTag()) != 0) {
1412         switch(tag) {
1413           default:
1414             input.SkipLastField();
1415             break;
1416           case 10: {
1417             Name = input.ReadString();
1418             break;
1419           }
1420           case 18: {
1421             if (value_ == null) {
1422               value_ = new global::Google.Protobuf.WellKnownTypes.Any();
1423             }
1424             input.ReadMessage(value_);
1425             break;
1426           }
1427         }
1428       }
1429     }
1430 
1431   }
1432 
1433   #endregion
1434 
1435 }
1436 
1437 #endregion Designer generated code
1438