1 // <auto-generated> 2 // Generated by the protocol buffer compiler. DO NOT EDIT! 3 // source: csharp/protos/unittest_issues.proto 4 // </auto-generated> 5 #pragma warning disable 1591, 0612, 3021, 8981 6 #region Designer generated code 7 8 using pb = global::Google.Protobuf; 9 using pbc = global::Google.Protobuf.Collections; 10 using pbr = global::Google.Protobuf.Reflection; 11 using scg = global::System.Collections.Generic; 12 namespace UnitTest.Issues.TestProtos { 13 14 /// <summary>Holder for reflection information generated from csharp/protos/unittest_issues.proto</summary> 15 public static partial class UnittestIssuesReflection { 16 17 #region Descriptor 18 /// <summary>File descriptor for csharp/protos/unittest_issues.proto</summary> 19 public static pbr::FileDescriptor Descriptor { 20 get { return descriptor; } 21 } 22 private static pbr::FileDescriptor descriptor; 23 UnittestIssuesReflection()24 static UnittestIssuesReflection() { 25 byte[] descriptorData = global::System.Convert.FromBase64String( 26 string.Concat( 27 "CiNjc2hhcnAvcHJvdG9zL3VuaXR0ZXN0X2lzc3Vlcy5wcm90bxIPdW5pdHRl", 28 "c3RfaXNzdWVzGhxnb29nbGUvcHJvdG9idWYvc3RydWN0LnByb3RvIicKCElz", 29 "c3VlMzA3GhsKCk5lc3RlZE9uY2UaDQoLTmVzdGVkVHdpY2UisAEKE05lZ2F0", 30 "aXZlRW51bU1lc3NhZ2USLAoFdmFsdWUYASABKA4yHS51bml0dGVzdF9pc3N1", 31 "ZXMuTmVnYXRpdmVFbnVtEjEKBnZhbHVlcxgCIAMoDjIdLnVuaXR0ZXN0X2lz", 32 "c3Vlcy5OZWdhdGl2ZUVudW1CAhAAEjgKDXBhY2tlZF92YWx1ZXMYAyADKA4y", 33 "HS51bml0dGVzdF9pc3N1ZXMuTmVnYXRpdmVFbnVtQgIQASIVCg9EZXByZWNh", 34 "dGVkQ2hpbGQ6AhgBIrkCChdEZXByZWNhdGVkRmllbGRzTWVzc2FnZRIaCg5Q", 35 "cmltaXRpdmVWYWx1ZRgBIAEoBUICGAESGgoOUHJpbWl0aXZlQXJyYXkYAiAD", 36 "KAVCAhgBEjoKDE1lc3NhZ2VWYWx1ZRgDIAEoCzIgLnVuaXR0ZXN0X2lzc3Vl", 37 "cy5EZXByZWNhdGVkQ2hpbGRCAhgBEjoKDE1lc3NhZ2VBcnJheRgEIAMoCzIg", 38 "LnVuaXR0ZXN0X2lzc3Vlcy5EZXByZWNhdGVkQ2hpbGRCAhgBEjYKCUVudW1W", 39 "YWx1ZRgFIAEoDjIfLnVuaXR0ZXN0X2lzc3Vlcy5EZXByZWNhdGVkRW51bUIC", 40 "GAESNgoJRW51bUFycmF5GAYgAygOMh8udW5pdHRlc3RfaXNzdWVzLkRlcHJl", 41 "Y2F0ZWRFbnVtQgIYASIZCglJdGVtRmllbGQSDAoEaXRlbRgBIAEoBSJECg1S", 42 "ZXNlcnZlZE5hbWVzEg0KBXR5cGVzGAEgASgFEhIKCmRlc2NyaXB0b3IYAiAB", 43 "KAUaEAoOU29tZU5lc3RlZFR5cGUioAEKFVRlc3RKc29uRmllbGRPcmRlcmlu", 44 "ZxITCgtwbGFpbl9pbnQzMhgEIAEoBRITCglvMV9zdHJpbmcYAiABKAlIABIS", 45 "CghvMV9pbnQzMhgFIAEoBUgAEhQKDHBsYWluX3N0cmluZxgBIAEoCRISCghv", 46 "Ml9pbnQzMhgGIAEoBUgBEhMKCW8yX3N0cmluZxgDIAEoCUgBQgQKAm8xQgQK", 47 "Am8yIksKDFRlc3RKc29uTmFtZRIMCgRuYW1lGAEgASgJEhkKC2Rlc2NyaXB0", 48 "aW9uGAIgASgJUgRkZXNjEhIKBGd1aWQYAyABKAlSBGV4aWQifwoMT25lb2ZN", 49 "ZXJnaW5nEg4KBHRleHQYASABKAlIABI2CgZuZXN0ZWQYAiABKAsyJC51bml0", 50 "dGVzdF9pc3N1ZXMuT25lb2ZNZXJnaW5nLk5lc3RlZEgAGh4KBk5lc3RlZBIJ", 51 "CgF4GAEgASgFEgkKAXkYAiABKAVCBwoFdmFsdWUiawoWTnVsbFZhbHVlT3V0", 52 "c2lkZVN0cnVjdBIWCgxzdHJpbmdfdmFsdWUYASABKAlIABIwCgpudWxsX3Zh", 53 "bHVlGAIgASgOMhouZ29vZ2xlLnByb3RvYnVmLk51bGxWYWx1ZUgAQgcKBXZh", 54 "bHVlIkUKE051bGxWYWx1ZU5vdEluT25lb2YSLgoKbnVsbF92YWx1ZRgCIAEo", 55 "DjIaLmdvb2dsZS5wcm90b2J1Zi5OdWxsVmFsdWUiYAoXTWl4ZWRSZWd1bGFy", 56 "QW5kT3B0aW9uYWwSFQoNcmVndWxhcl9maWVsZBgBIAEoCRIbCg5vcHRpb25h", 57 "bF9maWVsZBgCIAEoCUgAiAEBQhEKD19vcHRpb25hbF9maWVsZCI5ChJPbmVv", 58 "ZldpdGhOb25lRmllbGQSCwoBeBgBIAEoCUgAEg4KBG5vbmUYAiABKAlIAEIG", 59 "CgR0ZXN0IjUKEU9uZW9mV2l0aE5vbmVOYW1lEgsKAXgYASABKAlIABILCgF5", 60 "GAIgASgJSABCBgoEbm9uZSKTAgoZRGlzYW1iaWd1YXRlQ29tbW9uTWVtYmVy", 61 "cxIjChtkaXNhbWJpZ3VhdGVfY29tbW9uX21lbWJlcnMYASABKAUSDQoFdHlw", 62 "ZXMYAiABKAUSEgoKZGVzY3JpcHRvchgDIAEoBRIOCgZlcXVhbHMYBCABKAUS", 63 "EQoJdG9fc3RyaW5nGAUgASgFEhUKDWdldF9oYXNoX2NvZGUYBiABKAUSEAoI", 64 "d3JpdGVfdG8YByABKAUSDQoFY2xvbmUYCCABKAUSFgoOY2FsY3VsYXRlX3Np", 65 "emUYCSABKAUSEgoKbWVyZ2VfZnJvbRgKIAEoBRIXCg9vbl9jb25zdHJ1Y3Rp", 66 "b24YCyABKAUSDgoGcGFyc2VyGAwgASgFIj0KEUlzc3VlMTE5ODdNZXNzYWdl", 67 "EgwKAWEYASABKAVSAWISDAoBYhgCIAEoBVIBYRIMCgFjGAMgASgFUgFkKlUK", 68 "DE5lZ2F0aXZlRW51bRIWChJORUdBVElWRV9FTlVNX1pFUk8QABIWCglGaXZl", 69 "QmVsb3cQ+///////////ARIVCghNaW51c09uZRD///////////8BKjYKDkRl", 70 "cHJlY2F0ZWRFbnVtEhcKD0RFUFJFQ0FURURfWkVSTxAAGgIIARIHCgNvbmUQ", 71 "ARoCGAFCHaoCGlVuaXRUZXN0Lklzc3Vlcy5UZXN0UHJvdG9zYgZwcm90bzM=")); 72 descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, 73 new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.StructReflection.Descriptor, }, 74 new pbr::GeneratedClrTypeInfo(new[] {typeof(global::UnitTest.Issues.TestProtos.NegativeEnum), typeof(global::UnitTest.Issues.TestProtos.DeprecatedEnum), }, null, new pbr::GeneratedClrTypeInfo[] { 75 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.Issue307), global::UnitTest.Issues.TestProtos.Issue307.Parser, null, null, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.Issue307.Types.NestedOnce), global::UnitTest.Issues.TestProtos.Issue307.Types.NestedOnce.Parser, null, null, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.Issue307.Types.NestedOnce.Types.NestedTwice), global::UnitTest.Issues.TestProtos.Issue307.Types.NestedOnce.Types.NestedTwice.Parser, null, null, null, null, null)})}), 76 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.NegativeEnumMessage), global::UnitTest.Issues.TestProtos.NegativeEnumMessage.Parser, new[]{ "Value", "Values", "PackedValues" }, null, null, null, null), 77 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.DeprecatedChild), global::UnitTest.Issues.TestProtos.DeprecatedChild.Parser, null, null, null, null, null), 78 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage), global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage.Parser, new[]{ "PrimitiveValue", "PrimitiveArray", "MessageValue", "MessageArray", "EnumValue", "EnumArray" }, null, null, null, null), 79 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.ItemField), global::UnitTest.Issues.TestProtos.ItemField.Parser, new[]{ "Item" }, null, null, null, null), 80 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.ReservedNames), global::UnitTest.Issues.TestProtos.ReservedNames.Parser, new[]{ "Types_", "Descriptor_" }, null, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.ReservedNames.Types.SomeNestedType), global::UnitTest.Issues.TestProtos.ReservedNames.Types.SomeNestedType.Parser, null, null, null, null, null)}), 81 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.TestJsonFieldOrdering), global::UnitTest.Issues.TestProtos.TestJsonFieldOrdering.Parser, new[]{ "PlainInt32", "O1String", "O1Int32", "PlainString", "O2Int32", "O2String" }, new[]{ "O1", "O2" }, null, null, null), 82 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.TestJsonName), global::UnitTest.Issues.TestProtos.TestJsonName.Parser, new[]{ "Name", "Description", "Guid" }, null, null, null, null), 83 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.OneofMerging), global::UnitTest.Issues.TestProtos.OneofMerging.Parser, new[]{ "Text", "Nested" }, new[]{ "Value" }, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested), global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested.Parser, new[]{ "X", "Y" }, null, null, null, null)}), 84 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.NullValueOutsideStruct), global::UnitTest.Issues.TestProtos.NullValueOutsideStruct.Parser, new[]{ "StringValue", "NullValue" }, new[]{ "Value" }, null, null, null), 85 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.NullValueNotInOneof), global::UnitTest.Issues.TestProtos.NullValueNotInOneof.Parser, new[]{ "NullValue" }, null, null, null, null), 86 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.MixedRegularAndOptional), global::UnitTest.Issues.TestProtos.MixedRegularAndOptional.Parser, new[]{ "RegularField", "OptionalField" }, new[]{ "OptionalField" }, null, null, null), 87 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.OneofWithNoneField), global::UnitTest.Issues.TestProtos.OneofWithNoneField.Parser, new[]{ "X", "None" }, new[]{ "Test" }, null, null, null), 88 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.OneofWithNoneName), global::UnitTest.Issues.TestProtos.OneofWithNoneName.Parser, new[]{ "X", "Y" }, new[]{ "None" }, null, null, null), 89 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.DisambiguateCommonMembers), global::UnitTest.Issues.TestProtos.DisambiguateCommonMembers.Parser, new[]{ "DisambiguateCommonMembers_", "Types_", "Descriptor_", "Equals_", "ToString_", "GetHashCode_", "WriteTo_", "Clone_", "CalculateSize_", "MergeFrom_", "OnConstruction_", "Parser_" }, null, null, null, null), 90 new pbr::GeneratedClrTypeInfo(typeof(global::UnitTest.Issues.TestProtos.Issue11987Message), global::UnitTest.Issues.TestProtos.Issue11987Message.Parser, new[]{ "A", "B", "C" }, null, null, null, null) 91 })); 92 } 93 #endregion 94 95 } 96 #region Enums 97 public enum NegativeEnum { 98 [pbr::OriginalName("NEGATIVE_ENUM_ZERO")] Zero = 0, 99 [pbr::OriginalName("FiveBelow")] FiveBelow = -5, 100 [pbr::OriginalName("MinusOne")] MinusOne = -1, 101 } 102 103 [global::System.ObsoleteAttribute] 104 public enum DeprecatedEnum { 105 [global::System.ObsoleteAttribute] 106 [pbr::OriginalName("DEPRECATED_ZERO")] DeprecatedZero = 0, 107 [pbr::OriginalName("one")] One = 1, 108 } 109 110 #endregion 111 112 #region Messages 113 /// <summary> 114 /// Issue 307: when generating doubly-nested types, any references 115 /// should be of the form A.Types.B.Types.C. 116 /// </summary> 117 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 118 public sealed partial class Issue307 : pb::IMessage<Issue307> 119 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 120 , pb::IBufferMessage 121 #endif 122 { 123 private static readonly pb::MessageParser<Issue307> _parser = new pb::MessageParser<Issue307>(() => new Issue307()); 124 private pb::UnknownFieldSet _unknownFields; 125 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 126 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 127 public static pb::MessageParser<Issue307> Parser { get { return _parser; } } 128 129 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 130 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 131 public static pbr::MessageDescriptor Descriptor { 132 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[0]; } 133 } 134 135 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 136 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 137 pbr::MessageDescriptor pb::IMessage.Descriptor { 138 get { return Descriptor; } 139 } 140 141 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 142 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Issue307()143 public Issue307() { 144 OnConstruction(); 145 } 146 OnConstruction()147 partial void OnConstruction(); 148 149 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 150 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Issue307(Issue307 other)151 public Issue307(Issue307 other) : this() { 152 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 153 } 154 155 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 156 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()157 public Issue307 Clone() { 158 return new Issue307(this); 159 } 160 161 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 162 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)163 public override bool Equals(object other) { 164 return Equals(other as Issue307); 165 } 166 167 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 168 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(Issue307 other)169 public bool Equals(Issue307 other) { 170 if (ReferenceEquals(other, null)) { 171 return false; 172 } 173 if (ReferenceEquals(other, this)) { 174 return true; 175 } 176 return Equals(_unknownFields, other._unknownFields); 177 } 178 179 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 180 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()181 public override int GetHashCode() { 182 int hash = 1; 183 if (_unknownFields != null) { 184 hash ^= _unknownFields.GetHashCode(); 185 } 186 return hash; 187 } 188 189 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 190 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()191 public override string ToString() { 192 return pb::JsonFormatter.ToDiagnosticString(this); 193 } 194 195 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 196 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)197 public void WriteTo(pb::CodedOutputStream output) { 198 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 199 output.WriteRawMessage(this); 200 #else 201 if (_unknownFields != null) { 202 _unknownFields.WriteTo(output); 203 } 204 #endif 205 } 206 207 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 208 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 209 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)210 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 211 if (_unknownFields != null) { 212 _unknownFields.WriteTo(ref output); 213 } 214 } 215 #endif 216 217 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 218 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()219 public int CalculateSize() { 220 int size = 0; 221 if (_unknownFields != null) { 222 size += _unknownFields.CalculateSize(); 223 } 224 return size; 225 } 226 227 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 228 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(Issue307 other)229 public void MergeFrom(Issue307 other) { 230 if (other == null) { 231 return; 232 } 233 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 234 } 235 236 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 237 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)238 public void MergeFrom(pb::CodedInputStream input) { 239 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 240 input.ReadRawMessage(this); 241 #else 242 uint tag; 243 while ((tag = input.ReadTag()) != 0) { 244 if ((tag & 7) == 4) { 245 // Abort on any end group tag. 246 return; 247 } 248 switch(tag) { 249 default: 250 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 251 break; 252 } 253 } 254 #endif 255 } 256 257 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 258 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 259 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)260 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 261 uint tag; 262 while ((tag = input.ReadTag()) != 0) { 263 if ((tag & 7) == 4) { 264 // Abort on any end group tag. 265 return; 266 } 267 switch(tag) { 268 default: 269 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 270 break; 271 } 272 } 273 } 274 #endif 275 276 #region Nested types 277 /// <summary>Container for nested types declared in the Issue307 message type.</summary> 278 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 279 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 280 public static partial class Types { 281 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 282 public sealed partial class NestedOnce : pb::IMessage<NestedOnce> 283 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 284 , pb::IBufferMessage 285 #endif 286 { 287 private static readonly pb::MessageParser<NestedOnce> _parser = new pb::MessageParser<NestedOnce>(() => new NestedOnce()); 288 private pb::UnknownFieldSet _unknownFields; 289 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 290 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 291 public static pb::MessageParser<NestedOnce> Parser { get { return _parser; } } 292 293 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 294 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 295 public static pbr::MessageDescriptor Descriptor { 296 get { return global::UnitTest.Issues.TestProtos.Issue307.Descriptor.NestedTypes[0]; } 297 } 298 299 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 300 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 301 pbr::MessageDescriptor pb::IMessage.Descriptor { 302 get { return Descriptor; } 303 } 304 305 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 306 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NestedOnce()307 public NestedOnce() { 308 OnConstruction(); 309 } 310 OnConstruction()311 partial void OnConstruction(); 312 313 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 314 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NestedOnce(NestedOnce other)315 public NestedOnce(NestedOnce other) : this() { 316 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 317 } 318 319 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 320 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()321 public NestedOnce Clone() { 322 return new NestedOnce(this); 323 } 324 325 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 326 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)327 public override bool Equals(object other) { 328 return Equals(other as NestedOnce); 329 } 330 331 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 332 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(NestedOnce other)333 public bool Equals(NestedOnce other) { 334 if (ReferenceEquals(other, null)) { 335 return false; 336 } 337 if (ReferenceEquals(other, this)) { 338 return true; 339 } 340 return Equals(_unknownFields, other._unknownFields); 341 } 342 343 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 344 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()345 public override int GetHashCode() { 346 int hash = 1; 347 if (_unknownFields != null) { 348 hash ^= _unknownFields.GetHashCode(); 349 } 350 return hash; 351 } 352 353 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 354 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()355 public override string ToString() { 356 return pb::JsonFormatter.ToDiagnosticString(this); 357 } 358 359 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 360 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)361 public void WriteTo(pb::CodedOutputStream output) { 362 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 363 output.WriteRawMessage(this); 364 #else 365 if (_unknownFields != null) { 366 _unknownFields.WriteTo(output); 367 } 368 #endif 369 } 370 371 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 372 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 373 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)374 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 375 if (_unknownFields != null) { 376 _unknownFields.WriteTo(ref output); 377 } 378 } 379 #endif 380 381 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 382 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()383 public int CalculateSize() { 384 int size = 0; 385 if (_unknownFields != null) { 386 size += _unknownFields.CalculateSize(); 387 } 388 return size; 389 } 390 391 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 392 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(NestedOnce other)393 public void MergeFrom(NestedOnce other) { 394 if (other == null) { 395 return; 396 } 397 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 398 } 399 400 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 401 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)402 public void MergeFrom(pb::CodedInputStream input) { 403 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 404 input.ReadRawMessage(this); 405 #else 406 uint tag; 407 while ((tag = input.ReadTag()) != 0) { 408 if ((tag & 7) == 4) { 409 // Abort on any end group tag. 410 return; 411 } 412 switch(tag) { 413 default: 414 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 415 break; 416 } 417 } 418 #endif 419 } 420 421 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 422 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 423 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)424 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 425 uint tag; 426 while ((tag = input.ReadTag()) != 0) { 427 if ((tag & 7) == 4) { 428 // Abort on any end group tag. 429 return; 430 } 431 switch(tag) { 432 default: 433 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 434 break; 435 } 436 } 437 } 438 #endif 439 440 #region Nested types 441 /// <summary>Container for nested types declared in the NestedOnce message type.</summary> 442 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 443 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 444 public static partial class Types { 445 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 446 public sealed partial class NestedTwice : pb::IMessage<NestedTwice> 447 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 448 , pb::IBufferMessage 449 #endif 450 { 451 private static readonly pb::MessageParser<NestedTwice> _parser = new pb::MessageParser<NestedTwice>(() => new NestedTwice()); 452 private pb::UnknownFieldSet _unknownFields; 453 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 454 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 455 public static pb::MessageParser<NestedTwice> Parser { get { return _parser; } } 456 457 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 458 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 459 public static pbr::MessageDescriptor Descriptor { 460 get { return global::UnitTest.Issues.TestProtos.Issue307.Types.NestedOnce.Descriptor.NestedTypes[0]; } 461 } 462 463 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 464 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 465 pbr::MessageDescriptor pb::IMessage.Descriptor { 466 get { return Descriptor; } 467 } 468 469 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 470 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NestedTwice()471 public NestedTwice() { 472 OnConstruction(); 473 } 474 OnConstruction()475 partial void OnConstruction(); 476 477 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 478 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NestedTwice(NestedTwice other)479 public NestedTwice(NestedTwice other) : this() { 480 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 481 } 482 483 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 484 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()485 public NestedTwice Clone() { 486 return new NestedTwice(this); 487 } 488 489 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 490 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)491 public override bool Equals(object other) { 492 return Equals(other as NestedTwice); 493 } 494 495 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 496 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(NestedTwice other)497 public bool Equals(NestedTwice other) { 498 if (ReferenceEquals(other, null)) { 499 return false; 500 } 501 if (ReferenceEquals(other, this)) { 502 return true; 503 } 504 return Equals(_unknownFields, other._unknownFields); 505 } 506 507 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 508 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()509 public override int GetHashCode() { 510 int hash = 1; 511 if (_unknownFields != null) { 512 hash ^= _unknownFields.GetHashCode(); 513 } 514 return hash; 515 } 516 517 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 518 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()519 public override string ToString() { 520 return pb::JsonFormatter.ToDiagnosticString(this); 521 } 522 523 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 524 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)525 public void WriteTo(pb::CodedOutputStream output) { 526 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 527 output.WriteRawMessage(this); 528 #else 529 if (_unknownFields != null) { 530 _unknownFields.WriteTo(output); 531 } 532 #endif 533 } 534 535 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 536 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 537 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)538 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 539 if (_unknownFields != null) { 540 _unknownFields.WriteTo(ref output); 541 } 542 } 543 #endif 544 545 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 546 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()547 public int CalculateSize() { 548 int size = 0; 549 if (_unknownFields != null) { 550 size += _unknownFields.CalculateSize(); 551 } 552 return size; 553 } 554 555 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 556 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(NestedTwice other)557 public void MergeFrom(NestedTwice other) { 558 if (other == null) { 559 return; 560 } 561 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 562 } 563 564 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 565 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)566 public void MergeFrom(pb::CodedInputStream input) { 567 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 568 input.ReadRawMessage(this); 569 #else 570 uint tag; 571 while ((tag = input.ReadTag()) != 0) { 572 if ((tag & 7) == 4) { 573 // Abort on any end group tag. 574 return; 575 } 576 switch(tag) { 577 default: 578 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 579 break; 580 } 581 } 582 #endif 583 } 584 585 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 586 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 587 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)588 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 589 uint tag; 590 while ((tag = input.ReadTag()) != 0) { 591 if ((tag & 7) == 4) { 592 // Abort on any end group tag. 593 return; 594 } 595 switch(tag) { 596 default: 597 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 598 break; 599 } 600 } 601 } 602 #endif 603 604 } 605 606 } 607 #endregion 608 609 } 610 611 } 612 #endregion 613 614 } 615 616 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 617 public sealed partial class NegativeEnumMessage : pb::IMessage<NegativeEnumMessage> 618 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 619 , pb::IBufferMessage 620 #endif 621 { 622 private static readonly pb::MessageParser<NegativeEnumMessage> _parser = new pb::MessageParser<NegativeEnumMessage>(() => new NegativeEnumMessage()); 623 private pb::UnknownFieldSet _unknownFields; 624 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 625 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 626 public static pb::MessageParser<NegativeEnumMessage> Parser { get { return _parser; } } 627 628 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 629 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 630 public static pbr::MessageDescriptor Descriptor { 631 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[1]; } 632 } 633 634 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 635 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 636 pbr::MessageDescriptor pb::IMessage.Descriptor { 637 get { return Descriptor; } 638 } 639 640 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 641 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NegativeEnumMessage()642 public NegativeEnumMessage() { 643 OnConstruction(); 644 } 645 OnConstruction()646 partial void OnConstruction(); 647 648 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 649 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NegativeEnumMessage(NegativeEnumMessage other)650 public NegativeEnumMessage(NegativeEnumMessage other) : this() { 651 value_ = other.value_; 652 values_ = other.values_.Clone(); 653 packedValues_ = other.packedValues_.Clone(); 654 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 655 } 656 657 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 658 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()659 public NegativeEnumMessage Clone() { 660 return new NegativeEnumMessage(this); 661 } 662 663 /// <summary>Field number for the "value" field.</summary> 664 public const int ValueFieldNumber = 1; 665 private global::UnitTest.Issues.TestProtos.NegativeEnum value_ = global::UnitTest.Issues.TestProtos.NegativeEnum.Zero; 666 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 667 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 668 public global::UnitTest.Issues.TestProtos.NegativeEnum Value { 669 get { return value_; } 670 set { 671 value_ = value; 672 } 673 } 674 675 /// <summary>Field number for the "values" field.</summary> 676 public const int ValuesFieldNumber = 2; 677 private static readonly pb::FieldCodec<global::UnitTest.Issues.TestProtos.NegativeEnum> _repeated_values_codec 678 = pb::FieldCodec.ForEnum(16, x => (int) x, x => (global::UnitTest.Issues.TestProtos.NegativeEnum) x); 679 private readonly pbc::RepeatedField<global::UnitTest.Issues.TestProtos.NegativeEnum> values_ = new pbc::RepeatedField<global::UnitTest.Issues.TestProtos.NegativeEnum>(); 680 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 681 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 682 public pbc::RepeatedField<global::UnitTest.Issues.TestProtos.NegativeEnum> Values { 683 get { return values_; } 684 } 685 686 /// <summary>Field number for the "packed_values" field.</summary> 687 public const int PackedValuesFieldNumber = 3; 688 private static readonly pb::FieldCodec<global::UnitTest.Issues.TestProtos.NegativeEnum> _repeated_packedValues_codec 689 = pb::FieldCodec.ForEnum(26, x => (int) x, x => (global::UnitTest.Issues.TestProtos.NegativeEnum) x); 690 private readonly pbc::RepeatedField<global::UnitTest.Issues.TestProtos.NegativeEnum> packedValues_ = new pbc::RepeatedField<global::UnitTest.Issues.TestProtos.NegativeEnum>(); 691 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 692 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 693 public pbc::RepeatedField<global::UnitTest.Issues.TestProtos.NegativeEnum> PackedValues { 694 get { return packedValues_; } 695 } 696 697 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 698 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)699 public override bool Equals(object other) { 700 return Equals(other as NegativeEnumMessage); 701 } 702 703 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 704 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(NegativeEnumMessage other)705 public bool Equals(NegativeEnumMessage other) { 706 if (ReferenceEquals(other, null)) { 707 return false; 708 } 709 if (ReferenceEquals(other, this)) { 710 return true; 711 } 712 if (Value != other.Value) return false; 713 if(!values_.Equals(other.values_)) return false; 714 if(!packedValues_.Equals(other.packedValues_)) return false; 715 return Equals(_unknownFields, other._unknownFields); 716 } 717 718 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 719 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()720 public override int GetHashCode() { 721 int hash = 1; 722 if (Value != global::UnitTest.Issues.TestProtos.NegativeEnum.Zero) hash ^= Value.GetHashCode(); 723 hash ^= values_.GetHashCode(); 724 hash ^= packedValues_.GetHashCode(); 725 if (_unknownFields != null) { 726 hash ^= _unknownFields.GetHashCode(); 727 } 728 return hash; 729 } 730 731 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 732 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()733 public override string ToString() { 734 return pb::JsonFormatter.ToDiagnosticString(this); 735 } 736 737 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 738 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)739 public void WriteTo(pb::CodedOutputStream output) { 740 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 741 output.WriteRawMessage(this); 742 #else 743 if (Value != global::UnitTest.Issues.TestProtos.NegativeEnum.Zero) { 744 output.WriteRawTag(8); 745 output.WriteEnum((int) Value); 746 } 747 values_.WriteTo(output, _repeated_values_codec); 748 packedValues_.WriteTo(output, _repeated_packedValues_codec); 749 if (_unknownFields != null) { 750 _unknownFields.WriteTo(output); 751 } 752 #endif 753 } 754 755 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 756 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 757 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)758 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 759 if (Value != global::UnitTest.Issues.TestProtos.NegativeEnum.Zero) { 760 output.WriteRawTag(8); 761 output.WriteEnum((int) Value); 762 } 763 values_.WriteTo(ref output, _repeated_values_codec); 764 packedValues_.WriteTo(ref output, _repeated_packedValues_codec); 765 if (_unknownFields != null) { 766 _unknownFields.WriteTo(ref output); 767 } 768 } 769 #endif 770 771 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 772 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()773 public int CalculateSize() { 774 int size = 0; 775 if (Value != global::UnitTest.Issues.TestProtos.NegativeEnum.Zero) { 776 size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Value); 777 } 778 size += values_.CalculateSize(_repeated_values_codec); 779 size += packedValues_.CalculateSize(_repeated_packedValues_codec); 780 if (_unknownFields != null) { 781 size += _unknownFields.CalculateSize(); 782 } 783 return size; 784 } 785 786 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 787 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(NegativeEnumMessage other)788 public void MergeFrom(NegativeEnumMessage other) { 789 if (other == null) { 790 return; 791 } 792 if (other.Value != global::UnitTest.Issues.TestProtos.NegativeEnum.Zero) { 793 Value = other.Value; 794 } 795 values_.Add(other.values_); 796 packedValues_.Add(other.packedValues_); 797 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 798 } 799 800 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 801 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)802 public void MergeFrom(pb::CodedInputStream input) { 803 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 804 input.ReadRawMessage(this); 805 #else 806 uint tag; 807 while ((tag = input.ReadTag()) != 0) { 808 if ((tag & 7) == 4) { 809 // Abort on any end group tag. 810 return; 811 } 812 switch(tag) { 813 default: 814 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 815 break; 816 case 8: { 817 Value = (global::UnitTest.Issues.TestProtos.NegativeEnum) input.ReadEnum(); 818 break; 819 } 820 case 18: 821 case 16: { 822 values_.AddEntriesFrom(input, _repeated_values_codec); 823 break; 824 } 825 case 26: 826 case 24: { 827 packedValues_.AddEntriesFrom(input, _repeated_packedValues_codec); 828 break; 829 } 830 } 831 } 832 #endif 833 } 834 835 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 836 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 837 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)838 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 839 uint tag; 840 while ((tag = input.ReadTag()) != 0) { 841 if ((tag & 7) == 4) { 842 // Abort on any end group tag. 843 return; 844 } 845 switch(tag) { 846 default: 847 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 848 break; 849 case 8: { 850 Value = (global::UnitTest.Issues.TestProtos.NegativeEnum) input.ReadEnum(); 851 break; 852 } 853 case 18: 854 case 16: { 855 values_.AddEntriesFrom(ref input, _repeated_values_codec); 856 break; 857 } 858 case 26: 859 case 24: { 860 packedValues_.AddEntriesFrom(ref input, _repeated_packedValues_codec); 861 break; 862 } 863 } 864 } 865 } 866 #endif 867 868 } 869 870 [global::System.ObsoleteAttribute] 871 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 872 public sealed partial class DeprecatedChild : pb::IMessage<DeprecatedChild> 873 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 874 , pb::IBufferMessage 875 #endif 876 { 877 private static readonly pb::MessageParser<DeprecatedChild> _parser = new pb::MessageParser<DeprecatedChild>(() => new DeprecatedChild()); 878 private pb::UnknownFieldSet _unknownFields; 879 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 880 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 881 public static pb::MessageParser<DeprecatedChild> Parser { get { return _parser; } } 882 883 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 884 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 885 public static pbr::MessageDescriptor Descriptor { 886 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[2]; } 887 } 888 889 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 890 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 891 pbr::MessageDescriptor pb::IMessage.Descriptor { 892 get { return Descriptor; } 893 } 894 895 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 896 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] DeprecatedChild()897 public DeprecatedChild() { 898 OnConstruction(); 899 } 900 OnConstruction()901 partial void OnConstruction(); 902 903 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 904 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] DeprecatedChild(DeprecatedChild other)905 public DeprecatedChild(DeprecatedChild other) : this() { 906 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 907 } 908 909 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 910 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()911 public DeprecatedChild Clone() { 912 return new DeprecatedChild(this); 913 } 914 915 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 916 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)917 public override bool Equals(object other) { 918 return Equals(other as DeprecatedChild); 919 } 920 921 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 922 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(DeprecatedChild other)923 public bool Equals(DeprecatedChild other) { 924 if (ReferenceEquals(other, null)) { 925 return false; 926 } 927 if (ReferenceEquals(other, this)) { 928 return true; 929 } 930 return Equals(_unknownFields, other._unknownFields); 931 } 932 933 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 934 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()935 public override int GetHashCode() { 936 int hash = 1; 937 if (_unknownFields != null) { 938 hash ^= _unknownFields.GetHashCode(); 939 } 940 return hash; 941 } 942 943 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 944 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()945 public override string ToString() { 946 return pb::JsonFormatter.ToDiagnosticString(this); 947 } 948 949 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 950 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)951 public void WriteTo(pb::CodedOutputStream output) { 952 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 953 output.WriteRawMessage(this); 954 #else 955 if (_unknownFields != null) { 956 _unknownFields.WriteTo(output); 957 } 958 #endif 959 } 960 961 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 962 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 963 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)964 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 965 if (_unknownFields != null) { 966 _unknownFields.WriteTo(ref output); 967 } 968 } 969 #endif 970 971 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 972 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()973 public int CalculateSize() { 974 int size = 0; 975 if (_unknownFields != null) { 976 size += _unknownFields.CalculateSize(); 977 } 978 return size; 979 } 980 981 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 982 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(DeprecatedChild other)983 public void MergeFrom(DeprecatedChild other) { 984 if (other == null) { 985 return; 986 } 987 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 988 } 989 990 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 991 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)992 public void MergeFrom(pb::CodedInputStream input) { 993 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 994 input.ReadRawMessage(this); 995 #else 996 uint tag; 997 while ((tag = input.ReadTag()) != 0) { 998 if ((tag & 7) == 4) { 999 // Abort on any end group tag. 1000 return; 1001 } 1002 switch(tag) { 1003 default: 1004 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 1005 break; 1006 } 1007 } 1008 #endif 1009 } 1010 1011 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1012 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1013 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)1014 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 1015 uint tag; 1016 while ((tag = input.ReadTag()) != 0) { 1017 if ((tag & 7) == 4) { 1018 // Abort on any end group tag. 1019 return; 1020 } 1021 switch(tag) { 1022 default: 1023 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 1024 break; 1025 } 1026 } 1027 } 1028 #endif 1029 1030 } 1031 1032 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 1033 public sealed partial class DeprecatedFieldsMessage : pb::IMessage<DeprecatedFieldsMessage> 1034 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1035 , pb::IBufferMessage 1036 #endif 1037 { 1038 private static readonly pb::MessageParser<DeprecatedFieldsMessage> _parser = new pb::MessageParser<DeprecatedFieldsMessage>(() => new DeprecatedFieldsMessage()); 1039 private pb::UnknownFieldSet _unknownFields; 1040 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1041 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1042 public static pb::MessageParser<DeprecatedFieldsMessage> Parser { get { return _parser; } } 1043 1044 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1045 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1046 public static pbr::MessageDescriptor Descriptor { 1047 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[3]; } 1048 } 1049 1050 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1051 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1052 pbr::MessageDescriptor pb::IMessage.Descriptor { 1053 get { return Descriptor; } 1054 } 1055 1056 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1057 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] DeprecatedFieldsMessage()1058 public DeprecatedFieldsMessage() { 1059 OnConstruction(); 1060 } 1061 OnConstruction()1062 partial void OnConstruction(); 1063 1064 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1065 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] DeprecatedFieldsMessage(DeprecatedFieldsMessage other)1066 public DeprecatedFieldsMessage(DeprecatedFieldsMessage other) : this() { 1067 primitiveValue_ = other.primitiveValue_; 1068 primitiveArray_ = other.primitiveArray_.Clone(); 1069 messageValue_ = other.messageValue_ != null ? other.messageValue_.Clone() : null; 1070 messageArray_ = other.messageArray_.Clone(); 1071 enumValue_ = other.enumValue_; 1072 enumArray_ = other.enumArray_.Clone(); 1073 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 1074 } 1075 1076 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1077 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()1078 public DeprecatedFieldsMessage Clone() { 1079 return new DeprecatedFieldsMessage(this); 1080 } 1081 1082 /// <summary>Field number for the "PrimitiveValue" field.</summary> 1083 public const int PrimitiveValueFieldNumber = 1; 1084 private int primitiveValue_; 1085 [global::System.ObsoleteAttribute] 1086 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1087 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1088 public int PrimitiveValue { 1089 get { return primitiveValue_; } 1090 set { 1091 primitiveValue_ = value; 1092 } 1093 } 1094 1095 /// <summary>Field number for the "PrimitiveArray" field.</summary> 1096 public const int PrimitiveArrayFieldNumber = 2; 1097 private static readonly pb::FieldCodec<int> _repeated_primitiveArray_codec 1098 = pb::FieldCodec.ForInt32(18); 1099 private readonly pbc::RepeatedField<int> primitiveArray_ = new pbc::RepeatedField<int>(); 1100 [global::System.ObsoleteAttribute] 1101 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1102 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1103 public pbc::RepeatedField<int> PrimitiveArray { 1104 get { return primitiveArray_; } 1105 } 1106 1107 /// <summary>Field number for the "MessageValue" field.</summary> 1108 public const int MessageValueFieldNumber = 3; 1109 private global::UnitTest.Issues.TestProtos.DeprecatedChild messageValue_; 1110 [global::System.ObsoleteAttribute] 1111 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1112 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1113 public global::UnitTest.Issues.TestProtos.DeprecatedChild MessageValue { 1114 get { return messageValue_; } 1115 set { 1116 messageValue_ = value; 1117 } 1118 } 1119 1120 /// <summary>Field number for the "MessageArray" field.</summary> 1121 public const int MessageArrayFieldNumber = 4; 1122 private static readonly pb::FieldCodec<global::UnitTest.Issues.TestProtos.DeprecatedChild> _repeated_messageArray_codec 1123 = pb::FieldCodec.ForMessage(34, global::UnitTest.Issues.TestProtos.DeprecatedChild.Parser); 1124 private readonly pbc::RepeatedField<global::UnitTest.Issues.TestProtos.DeprecatedChild> messageArray_ = new pbc::RepeatedField<global::UnitTest.Issues.TestProtos.DeprecatedChild>(); 1125 [global::System.ObsoleteAttribute] 1126 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1127 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1128 public pbc::RepeatedField<global::UnitTest.Issues.TestProtos.DeprecatedChild> MessageArray { 1129 get { return messageArray_; } 1130 } 1131 1132 /// <summary>Field number for the "EnumValue" field.</summary> 1133 public const int EnumValueFieldNumber = 5; 1134 private global::UnitTest.Issues.TestProtos.DeprecatedEnum enumValue_ = global::UnitTest.Issues.TestProtos.DeprecatedEnum.DeprecatedZero; 1135 [global::System.ObsoleteAttribute] 1136 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1137 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1138 public global::UnitTest.Issues.TestProtos.DeprecatedEnum EnumValue { 1139 get { return enumValue_; } 1140 set { 1141 enumValue_ = value; 1142 } 1143 } 1144 1145 /// <summary>Field number for the "EnumArray" field.</summary> 1146 public const int EnumArrayFieldNumber = 6; 1147 private static readonly pb::FieldCodec<global::UnitTest.Issues.TestProtos.DeprecatedEnum> _repeated_enumArray_codec 1148 = pb::FieldCodec.ForEnum(50, x => (int) x, x => (global::UnitTest.Issues.TestProtos.DeprecatedEnum) x); 1149 private readonly pbc::RepeatedField<global::UnitTest.Issues.TestProtos.DeprecatedEnum> enumArray_ = new pbc::RepeatedField<global::UnitTest.Issues.TestProtos.DeprecatedEnum>(); 1150 [global::System.ObsoleteAttribute] 1151 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1152 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1153 public pbc::RepeatedField<global::UnitTest.Issues.TestProtos.DeprecatedEnum> EnumArray { 1154 get { return enumArray_; } 1155 } 1156 1157 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1158 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)1159 public override bool Equals(object other) { 1160 return Equals(other as DeprecatedFieldsMessage); 1161 } 1162 1163 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1164 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(DeprecatedFieldsMessage other)1165 public bool Equals(DeprecatedFieldsMessage other) { 1166 if (ReferenceEquals(other, null)) { 1167 return false; 1168 } 1169 if (ReferenceEquals(other, this)) { 1170 return true; 1171 } 1172 if (PrimitiveValue != other.PrimitiveValue) return false; 1173 if(!primitiveArray_.Equals(other.primitiveArray_)) return false; 1174 if (!object.Equals(MessageValue, other.MessageValue)) return false; 1175 if(!messageArray_.Equals(other.messageArray_)) return false; 1176 if (EnumValue != other.EnumValue) return false; 1177 if(!enumArray_.Equals(other.enumArray_)) return false; 1178 return Equals(_unknownFields, other._unknownFields); 1179 } 1180 1181 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1182 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()1183 public override int GetHashCode() { 1184 int hash = 1; 1185 if (PrimitiveValue != 0) hash ^= PrimitiveValue.GetHashCode(); 1186 hash ^= primitiveArray_.GetHashCode(); 1187 if (messageValue_ != null) hash ^= MessageValue.GetHashCode(); 1188 hash ^= messageArray_.GetHashCode(); 1189 if (EnumValue != global::UnitTest.Issues.TestProtos.DeprecatedEnum.DeprecatedZero) hash ^= EnumValue.GetHashCode(); 1190 hash ^= enumArray_.GetHashCode(); 1191 if (_unknownFields != null) { 1192 hash ^= _unknownFields.GetHashCode(); 1193 } 1194 return hash; 1195 } 1196 1197 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1198 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()1199 public override string ToString() { 1200 return pb::JsonFormatter.ToDiagnosticString(this); 1201 } 1202 1203 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1204 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)1205 public void WriteTo(pb::CodedOutputStream output) { 1206 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1207 output.WriteRawMessage(this); 1208 #else 1209 if (PrimitiveValue != 0) { 1210 output.WriteRawTag(8); 1211 output.WriteInt32(PrimitiveValue); 1212 } 1213 primitiveArray_.WriteTo(output, _repeated_primitiveArray_codec); 1214 if (messageValue_ != null) { 1215 output.WriteRawTag(26); 1216 output.WriteMessage(MessageValue); 1217 } 1218 messageArray_.WriteTo(output, _repeated_messageArray_codec); 1219 if (EnumValue != global::UnitTest.Issues.TestProtos.DeprecatedEnum.DeprecatedZero) { 1220 output.WriteRawTag(40); 1221 output.WriteEnum((int) EnumValue); 1222 } 1223 enumArray_.WriteTo(output, _repeated_enumArray_codec); 1224 if (_unknownFields != null) { 1225 _unknownFields.WriteTo(output); 1226 } 1227 #endif 1228 } 1229 1230 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1231 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1232 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)1233 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 1234 if (PrimitiveValue != 0) { 1235 output.WriteRawTag(8); 1236 output.WriteInt32(PrimitiveValue); 1237 } 1238 primitiveArray_.WriteTo(ref output, _repeated_primitiveArray_codec); 1239 if (messageValue_ != null) { 1240 output.WriteRawTag(26); 1241 output.WriteMessage(MessageValue); 1242 } 1243 messageArray_.WriteTo(ref output, _repeated_messageArray_codec); 1244 if (EnumValue != global::UnitTest.Issues.TestProtos.DeprecatedEnum.DeprecatedZero) { 1245 output.WriteRawTag(40); 1246 output.WriteEnum((int) EnumValue); 1247 } 1248 enumArray_.WriteTo(ref output, _repeated_enumArray_codec); 1249 if (_unknownFields != null) { 1250 _unknownFields.WriteTo(ref output); 1251 } 1252 } 1253 #endif 1254 1255 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1256 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()1257 public int CalculateSize() { 1258 int size = 0; 1259 if (PrimitiveValue != 0) { 1260 size += 1 + pb::CodedOutputStream.ComputeInt32Size(PrimitiveValue); 1261 } 1262 size += primitiveArray_.CalculateSize(_repeated_primitiveArray_codec); 1263 if (messageValue_ != null) { 1264 size += 1 + pb::CodedOutputStream.ComputeMessageSize(MessageValue); 1265 } 1266 size += messageArray_.CalculateSize(_repeated_messageArray_codec); 1267 if (EnumValue != global::UnitTest.Issues.TestProtos.DeprecatedEnum.DeprecatedZero) { 1268 size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) EnumValue); 1269 } 1270 size += enumArray_.CalculateSize(_repeated_enumArray_codec); 1271 if (_unknownFields != null) { 1272 size += _unknownFields.CalculateSize(); 1273 } 1274 return size; 1275 } 1276 1277 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1278 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(DeprecatedFieldsMessage other)1279 public void MergeFrom(DeprecatedFieldsMessage other) { 1280 if (other == null) { 1281 return; 1282 } 1283 if (other.PrimitiveValue != 0) { 1284 PrimitiveValue = other.PrimitiveValue; 1285 } 1286 primitiveArray_.Add(other.primitiveArray_); 1287 if (other.messageValue_ != null) { 1288 if (messageValue_ == null) { 1289 MessageValue = new global::UnitTest.Issues.TestProtos.DeprecatedChild(); 1290 } 1291 MessageValue.MergeFrom(other.MessageValue); 1292 } 1293 messageArray_.Add(other.messageArray_); 1294 if (other.EnumValue != global::UnitTest.Issues.TestProtos.DeprecatedEnum.DeprecatedZero) { 1295 EnumValue = other.EnumValue; 1296 } 1297 enumArray_.Add(other.enumArray_); 1298 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 1299 } 1300 1301 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1302 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)1303 public void MergeFrom(pb::CodedInputStream input) { 1304 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1305 input.ReadRawMessage(this); 1306 #else 1307 uint tag; 1308 while ((tag = input.ReadTag()) != 0) { 1309 if ((tag & 7) == 4) { 1310 // Abort on any end group tag. 1311 return; 1312 } 1313 switch(tag) { 1314 default: 1315 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 1316 break; 1317 case 8: { 1318 PrimitiveValue = input.ReadInt32(); 1319 break; 1320 } 1321 case 18: 1322 case 16: { 1323 primitiveArray_.AddEntriesFrom(input, _repeated_primitiveArray_codec); 1324 break; 1325 } 1326 case 26: { 1327 if (messageValue_ == null) { 1328 MessageValue = new global::UnitTest.Issues.TestProtos.DeprecatedChild(); 1329 } 1330 input.ReadMessage(MessageValue); 1331 break; 1332 } 1333 case 34: { 1334 messageArray_.AddEntriesFrom(input, _repeated_messageArray_codec); 1335 break; 1336 } 1337 case 40: { 1338 EnumValue = (global::UnitTest.Issues.TestProtos.DeprecatedEnum) input.ReadEnum(); 1339 break; 1340 } 1341 case 50: 1342 case 48: { 1343 enumArray_.AddEntriesFrom(input, _repeated_enumArray_codec); 1344 break; 1345 } 1346 } 1347 } 1348 #endif 1349 } 1350 1351 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1352 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1353 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)1354 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 1355 uint tag; 1356 while ((tag = input.ReadTag()) != 0) { 1357 if ((tag & 7) == 4) { 1358 // Abort on any end group tag. 1359 return; 1360 } 1361 switch(tag) { 1362 default: 1363 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 1364 break; 1365 case 8: { 1366 PrimitiveValue = input.ReadInt32(); 1367 break; 1368 } 1369 case 18: 1370 case 16: { 1371 primitiveArray_.AddEntriesFrom(ref input, _repeated_primitiveArray_codec); 1372 break; 1373 } 1374 case 26: { 1375 if (messageValue_ == null) { 1376 MessageValue = new global::UnitTest.Issues.TestProtos.DeprecatedChild(); 1377 } 1378 input.ReadMessage(MessageValue); 1379 break; 1380 } 1381 case 34: { 1382 messageArray_.AddEntriesFrom(ref input, _repeated_messageArray_codec); 1383 break; 1384 } 1385 case 40: { 1386 EnumValue = (global::UnitTest.Issues.TestProtos.DeprecatedEnum) input.ReadEnum(); 1387 break; 1388 } 1389 case 50: 1390 case 48: { 1391 enumArray_.AddEntriesFrom(ref input, _repeated_enumArray_codec); 1392 break; 1393 } 1394 } 1395 } 1396 } 1397 #endif 1398 1399 } 1400 1401 /// <summary> 1402 /// Issue 45: http://code.google.com/p/protobuf-csharp-port/issues/detail?id=45 1403 /// </summary> 1404 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 1405 public sealed partial class ItemField : pb::IMessage<ItemField> 1406 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1407 , pb::IBufferMessage 1408 #endif 1409 { 1410 private static readonly pb::MessageParser<ItemField> _parser = new pb::MessageParser<ItemField>(() => new ItemField()); 1411 private pb::UnknownFieldSet _unknownFields; 1412 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1413 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1414 public static pb::MessageParser<ItemField> Parser { get { return _parser; } } 1415 1416 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1417 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1418 public static pbr::MessageDescriptor Descriptor { 1419 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[4]; } 1420 } 1421 1422 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1423 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1424 pbr::MessageDescriptor pb::IMessage.Descriptor { 1425 get { return Descriptor; } 1426 } 1427 1428 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1429 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ItemField()1430 public ItemField() { 1431 OnConstruction(); 1432 } 1433 OnConstruction()1434 partial void OnConstruction(); 1435 1436 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1437 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ItemField(ItemField other)1438 public ItemField(ItemField other) : this() { 1439 item_ = other.item_; 1440 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 1441 } 1442 1443 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1444 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()1445 public ItemField Clone() { 1446 return new ItemField(this); 1447 } 1448 1449 /// <summary>Field number for the "item" field.</summary> 1450 public const int ItemFieldNumber = 1; 1451 private int item_; 1452 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1453 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1454 public int Item { 1455 get { return item_; } 1456 set { 1457 item_ = value; 1458 } 1459 } 1460 1461 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1462 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)1463 public override bool Equals(object other) { 1464 return Equals(other as ItemField); 1465 } 1466 1467 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1468 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(ItemField other)1469 public bool Equals(ItemField other) { 1470 if (ReferenceEquals(other, null)) { 1471 return false; 1472 } 1473 if (ReferenceEquals(other, this)) { 1474 return true; 1475 } 1476 if (Item != other.Item) return false; 1477 return Equals(_unknownFields, other._unknownFields); 1478 } 1479 1480 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1481 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()1482 public override int GetHashCode() { 1483 int hash = 1; 1484 if (Item != 0) hash ^= Item.GetHashCode(); 1485 if (_unknownFields != null) { 1486 hash ^= _unknownFields.GetHashCode(); 1487 } 1488 return hash; 1489 } 1490 1491 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1492 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()1493 public override string ToString() { 1494 return pb::JsonFormatter.ToDiagnosticString(this); 1495 } 1496 1497 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1498 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)1499 public void WriteTo(pb::CodedOutputStream output) { 1500 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1501 output.WriteRawMessage(this); 1502 #else 1503 if (Item != 0) { 1504 output.WriteRawTag(8); 1505 output.WriteInt32(Item); 1506 } 1507 if (_unknownFields != null) { 1508 _unknownFields.WriteTo(output); 1509 } 1510 #endif 1511 } 1512 1513 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1514 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1515 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)1516 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 1517 if (Item != 0) { 1518 output.WriteRawTag(8); 1519 output.WriteInt32(Item); 1520 } 1521 if (_unknownFields != null) { 1522 _unknownFields.WriteTo(ref output); 1523 } 1524 } 1525 #endif 1526 1527 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1528 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()1529 public int CalculateSize() { 1530 int size = 0; 1531 if (Item != 0) { 1532 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Item); 1533 } 1534 if (_unknownFields != null) { 1535 size += _unknownFields.CalculateSize(); 1536 } 1537 return size; 1538 } 1539 1540 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1541 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(ItemField other)1542 public void MergeFrom(ItemField other) { 1543 if (other == null) { 1544 return; 1545 } 1546 if (other.Item != 0) { 1547 Item = other.Item; 1548 } 1549 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 1550 } 1551 1552 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1553 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)1554 public void MergeFrom(pb::CodedInputStream input) { 1555 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1556 input.ReadRawMessage(this); 1557 #else 1558 uint tag; 1559 while ((tag = input.ReadTag()) != 0) { 1560 if ((tag & 7) == 4) { 1561 // Abort on any end group tag. 1562 return; 1563 } 1564 switch(tag) { 1565 default: 1566 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 1567 break; 1568 case 8: { 1569 Item = input.ReadInt32(); 1570 break; 1571 } 1572 } 1573 } 1574 #endif 1575 } 1576 1577 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1578 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1579 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)1580 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 1581 uint tag; 1582 while ((tag = input.ReadTag()) != 0) { 1583 if ((tag & 7) == 4) { 1584 // Abort on any end group tag. 1585 return; 1586 } 1587 switch(tag) { 1588 default: 1589 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 1590 break; 1591 case 8: { 1592 Item = input.ReadInt32(); 1593 break; 1594 } 1595 } 1596 } 1597 } 1598 #endif 1599 1600 } 1601 1602 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 1603 public sealed partial class ReservedNames : pb::IMessage<ReservedNames> 1604 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1605 , pb::IBufferMessage 1606 #endif 1607 { 1608 private static readonly pb::MessageParser<ReservedNames> _parser = new pb::MessageParser<ReservedNames>(() => new ReservedNames()); 1609 private pb::UnknownFieldSet _unknownFields; 1610 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1611 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1612 public static pb::MessageParser<ReservedNames> Parser { get { return _parser; } } 1613 1614 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1615 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1616 public static pbr::MessageDescriptor Descriptor { 1617 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[5]; } 1618 } 1619 1620 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1621 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1622 pbr::MessageDescriptor pb::IMessage.Descriptor { 1623 get { return Descriptor; } 1624 } 1625 1626 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1627 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ReservedNames()1628 public ReservedNames() { 1629 OnConstruction(); 1630 } 1631 OnConstruction()1632 partial void OnConstruction(); 1633 1634 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1635 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ReservedNames(ReservedNames other)1636 public ReservedNames(ReservedNames other) : this() { 1637 types_ = other.types_; 1638 descriptor_ = other.descriptor_; 1639 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 1640 } 1641 1642 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1643 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()1644 public ReservedNames Clone() { 1645 return new ReservedNames(this); 1646 } 1647 1648 /// <summary>Field number for the "types" field.</summary> 1649 public const int Types_FieldNumber = 1; 1650 private int types_; 1651 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1652 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1653 public int Types_ { 1654 get { return types_; } 1655 set { 1656 types_ = value; 1657 } 1658 } 1659 1660 /// <summary>Field number for the "descriptor" field.</summary> 1661 public const int Descriptor_FieldNumber = 2; 1662 private int descriptor_; 1663 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1664 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1665 public int Descriptor_ { 1666 get { return descriptor_; } 1667 set { 1668 descriptor_ = value; 1669 } 1670 } 1671 1672 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1673 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)1674 public override bool Equals(object other) { 1675 return Equals(other as ReservedNames); 1676 } 1677 1678 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1679 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(ReservedNames other)1680 public bool Equals(ReservedNames other) { 1681 if (ReferenceEquals(other, null)) { 1682 return false; 1683 } 1684 if (ReferenceEquals(other, this)) { 1685 return true; 1686 } 1687 if (Types_ != other.Types_) return false; 1688 if (Descriptor_ != other.Descriptor_) return false; 1689 return Equals(_unknownFields, other._unknownFields); 1690 } 1691 1692 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1693 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()1694 public override int GetHashCode() { 1695 int hash = 1; 1696 if (Types_ != 0) hash ^= Types_.GetHashCode(); 1697 if (Descriptor_ != 0) hash ^= Descriptor_.GetHashCode(); 1698 if (_unknownFields != null) { 1699 hash ^= _unknownFields.GetHashCode(); 1700 } 1701 return hash; 1702 } 1703 1704 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1705 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()1706 public override string ToString() { 1707 return pb::JsonFormatter.ToDiagnosticString(this); 1708 } 1709 1710 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1711 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)1712 public void WriteTo(pb::CodedOutputStream output) { 1713 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1714 output.WriteRawMessage(this); 1715 #else 1716 if (Types_ != 0) { 1717 output.WriteRawTag(8); 1718 output.WriteInt32(Types_); 1719 } 1720 if (Descriptor_ != 0) { 1721 output.WriteRawTag(16); 1722 output.WriteInt32(Descriptor_); 1723 } 1724 if (_unknownFields != null) { 1725 _unknownFields.WriteTo(output); 1726 } 1727 #endif 1728 } 1729 1730 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1731 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1732 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)1733 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 1734 if (Types_ != 0) { 1735 output.WriteRawTag(8); 1736 output.WriteInt32(Types_); 1737 } 1738 if (Descriptor_ != 0) { 1739 output.WriteRawTag(16); 1740 output.WriteInt32(Descriptor_); 1741 } 1742 if (_unknownFields != null) { 1743 _unknownFields.WriteTo(ref output); 1744 } 1745 } 1746 #endif 1747 1748 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1749 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()1750 public int CalculateSize() { 1751 int size = 0; 1752 if (Types_ != 0) { 1753 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Types_); 1754 } 1755 if (Descriptor_ != 0) { 1756 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Descriptor_); 1757 } 1758 if (_unknownFields != null) { 1759 size += _unknownFields.CalculateSize(); 1760 } 1761 return size; 1762 } 1763 1764 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1765 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(ReservedNames other)1766 public void MergeFrom(ReservedNames other) { 1767 if (other == null) { 1768 return; 1769 } 1770 if (other.Types_ != 0) { 1771 Types_ = other.Types_; 1772 } 1773 if (other.Descriptor_ != 0) { 1774 Descriptor_ = other.Descriptor_; 1775 } 1776 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 1777 } 1778 1779 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1780 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)1781 public void MergeFrom(pb::CodedInputStream input) { 1782 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1783 input.ReadRawMessage(this); 1784 #else 1785 uint tag; 1786 while ((tag = input.ReadTag()) != 0) { 1787 if ((tag & 7) == 4) { 1788 // Abort on any end group tag. 1789 return; 1790 } 1791 switch(tag) { 1792 default: 1793 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 1794 break; 1795 case 8: { 1796 Types_ = input.ReadInt32(); 1797 break; 1798 } 1799 case 16: { 1800 Descriptor_ = input.ReadInt32(); 1801 break; 1802 } 1803 } 1804 } 1805 #endif 1806 } 1807 1808 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1809 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1810 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)1811 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 1812 uint tag; 1813 while ((tag = input.ReadTag()) != 0) { 1814 if ((tag & 7) == 4) { 1815 // Abort on any end group tag. 1816 return; 1817 } 1818 switch(tag) { 1819 default: 1820 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 1821 break; 1822 case 8: { 1823 Types_ = input.ReadInt32(); 1824 break; 1825 } 1826 case 16: { 1827 Descriptor_ = input.ReadInt32(); 1828 break; 1829 } 1830 } 1831 } 1832 } 1833 #endif 1834 1835 #region Nested types 1836 /// <summary>Container for nested types declared in the ReservedNames message type.</summary> 1837 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1838 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1839 public static partial class Types { 1840 /// <summary> 1841 /// Force a nested type called Types 1842 /// </summary> 1843 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 1844 public sealed partial class SomeNestedType : pb::IMessage<SomeNestedType> 1845 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1846 , pb::IBufferMessage 1847 #endif 1848 { 1849 private static readonly pb::MessageParser<SomeNestedType> _parser = new pb::MessageParser<SomeNestedType>(() => new SomeNestedType()); 1850 private pb::UnknownFieldSet _unknownFields; 1851 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1852 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1853 public static pb::MessageParser<SomeNestedType> Parser { get { return _parser; } } 1854 1855 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1856 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1857 public static pbr::MessageDescriptor Descriptor { 1858 get { return global::UnitTest.Issues.TestProtos.ReservedNames.Descriptor.NestedTypes[0]; } 1859 } 1860 1861 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1862 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 1863 pbr::MessageDescriptor pb::IMessage.Descriptor { 1864 get { return Descriptor; } 1865 } 1866 1867 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1868 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] SomeNestedType()1869 public SomeNestedType() { 1870 OnConstruction(); 1871 } 1872 OnConstruction()1873 partial void OnConstruction(); 1874 1875 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1876 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] SomeNestedType(SomeNestedType other)1877 public SomeNestedType(SomeNestedType other) : this() { 1878 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 1879 } 1880 1881 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1882 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()1883 public SomeNestedType Clone() { 1884 return new SomeNestedType(this); 1885 } 1886 1887 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1888 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)1889 public override bool Equals(object other) { 1890 return Equals(other as SomeNestedType); 1891 } 1892 1893 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1894 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(SomeNestedType other)1895 public bool Equals(SomeNestedType other) { 1896 if (ReferenceEquals(other, null)) { 1897 return false; 1898 } 1899 if (ReferenceEquals(other, this)) { 1900 return true; 1901 } 1902 return Equals(_unknownFields, other._unknownFields); 1903 } 1904 1905 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1906 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()1907 public override int GetHashCode() { 1908 int hash = 1; 1909 if (_unknownFields != null) { 1910 hash ^= _unknownFields.GetHashCode(); 1911 } 1912 return hash; 1913 } 1914 1915 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1916 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()1917 public override string ToString() { 1918 return pb::JsonFormatter.ToDiagnosticString(this); 1919 } 1920 1921 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1922 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)1923 public void WriteTo(pb::CodedOutputStream output) { 1924 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1925 output.WriteRawMessage(this); 1926 #else 1927 if (_unknownFields != null) { 1928 _unknownFields.WriteTo(output); 1929 } 1930 #endif 1931 } 1932 1933 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1934 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1935 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)1936 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 1937 if (_unknownFields != null) { 1938 _unknownFields.WriteTo(ref output); 1939 } 1940 } 1941 #endif 1942 1943 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1944 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()1945 public int CalculateSize() { 1946 int size = 0; 1947 if (_unknownFields != null) { 1948 size += _unknownFields.CalculateSize(); 1949 } 1950 return size; 1951 } 1952 1953 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1954 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(SomeNestedType other)1955 public void MergeFrom(SomeNestedType other) { 1956 if (other == null) { 1957 return; 1958 } 1959 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 1960 } 1961 1962 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1963 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)1964 public void MergeFrom(pb::CodedInputStream input) { 1965 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1966 input.ReadRawMessage(this); 1967 #else 1968 uint tag; 1969 while ((tag = input.ReadTag()) != 0) { 1970 if ((tag & 7) == 4) { 1971 // Abort on any end group tag. 1972 return; 1973 } 1974 switch(tag) { 1975 default: 1976 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 1977 break; 1978 } 1979 } 1980 #endif 1981 } 1982 1983 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 1984 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 1985 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)1986 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 1987 uint tag; 1988 while ((tag = input.ReadTag()) != 0) { 1989 if ((tag & 7) == 4) { 1990 // Abort on any end group tag. 1991 return; 1992 } 1993 switch(tag) { 1994 default: 1995 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 1996 break; 1997 } 1998 } 1999 } 2000 #endif 2001 2002 } 2003 2004 } 2005 #endregion 2006 2007 } 2008 2009 /// <summary> 2010 /// These fields are deliberately not declared in numeric 2011 /// order, and the oneof fields aren't contiguous either. 2012 /// This allows for reasonably robust tests of JSON output 2013 /// ordering. 2014 /// TestFieldOrderings in unittest_proto3.proto is similar, 2015 /// but doesn't include oneofs. 2016 /// TODO: Consider adding oneofs to TestFieldOrderings, although 2017 /// that will require fixing other tests in multiple platforms. 2018 /// Alternatively, consider just adding this to 2019 /// unittest_proto3.proto if multiple platforms want it. 2020 /// </summary> 2021 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 2022 public sealed partial class TestJsonFieldOrdering : pb::IMessage<TestJsonFieldOrdering> 2023 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2024 , pb::IBufferMessage 2025 #endif 2026 { 2027 private static readonly pb::MessageParser<TestJsonFieldOrdering> _parser = new pb::MessageParser<TestJsonFieldOrdering>(() => new TestJsonFieldOrdering()); 2028 private pb::UnknownFieldSet _unknownFields; 2029 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2030 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2031 public static pb::MessageParser<TestJsonFieldOrdering> Parser { get { return _parser; } } 2032 2033 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2034 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2035 public static pbr::MessageDescriptor Descriptor { 2036 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[6]; } 2037 } 2038 2039 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2040 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2041 pbr::MessageDescriptor pb::IMessage.Descriptor { 2042 get { return Descriptor; } 2043 } 2044 2045 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2046 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] TestJsonFieldOrdering()2047 public TestJsonFieldOrdering() { 2048 OnConstruction(); 2049 } 2050 OnConstruction()2051 partial void OnConstruction(); 2052 2053 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2054 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] TestJsonFieldOrdering(TestJsonFieldOrdering other)2055 public TestJsonFieldOrdering(TestJsonFieldOrdering other) : this() { 2056 plainInt32_ = other.plainInt32_; 2057 plainString_ = other.plainString_; 2058 switch (other.O1Case) { 2059 case O1OneofCase.O1String: 2060 O1String = other.O1String; 2061 break; 2062 case O1OneofCase.O1Int32: 2063 O1Int32 = other.O1Int32; 2064 break; 2065 } 2066 2067 switch (other.O2Case) { 2068 case O2OneofCase.O2Int32: 2069 O2Int32 = other.O2Int32; 2070 break; 2071 case O2OneofCase.O2String: 2072 O2String = other.O2String; 2073 break; 2074 } 2075 2076 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 2077 } 2078 2079 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2080 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()2081 public TestJsonFieldOrdering Clone() { 2082 return new TestJsonFieldOrdering(this); 2083 } 2084 2085 /// <summary>Field number for the "plain_int32" field.</summary> 2086 public const int PlainInt32FieldNumber = 4; 2087 private int plainInt32_; 2088 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2089 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2090 public int PlainInt32 { 2091 get { return plainInt32_; } 2092 set { 2093 plainInt32_ = value; 2094 } 2095 } 2096 2097 /// <summary>Field number for the "o1_string" field.</summary> 2098 public const int O1StringFieldNumber = 2; 2099 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2100 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2101 public string O1String { 2102 get { return HasO1String ? (string) o1_ : ""; } 2103 set { 2104 o1_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 2105 o1Case_ = O1OneofCase.O1String; 2106 } 2107 } 2108 /// <summary>Gets whether the "o1_string" field is set</summary> 2109 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2110 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2111 public bool HasO1String { 2112 get { return o1Case_ == O1OneofCase.O1String; } 2113 } 2114 /// <summary> Clears the value of the oneof if it's currently set to "o1_string" </summary> 2115 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2116 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearO1String()2117 public void ClearO1String() { 2118 if (HasO1String) { 2119 ClearO1(); 2120 } 2121 } 2122 2123 /// <summary>Field number for the "o1_int32" field.</summary> 2124 public const int O1Int32FieldNumber = 5; 2125 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2126 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2127 public int O1Int32 { 2128 get { return HasO1Int32 ? (int) o1_ : 0; } 2129 set { 2130 o1_ = value; 2131 o1Case_ = O1OneofCase.O1Int32; 2132 } 2133 } 2134 /// <summary>Gets whether the "o1_int32" field is set</summary> 2135 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2136 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2137 public bool HasO1Int32 { 2138 get { return o1Case_ == O1OneofCase.O1Int32; } 2139 } 2140 /// <summary> Clears the value of the oneof if it's currently set to "o1_int32" </summary> 2141 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2142 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearO1Int32()2143 public void ClearO1Int32() { 2144 if (HasO1Int32) { 2145 ClearO1(); 2146 } 2147 } 2148 2149 /// <summary>Field number for the "plain_string" field.</summary> 2150 public const int PlainStringFieldNumber = 1; 2151 private string plainString_ = ""; 2152 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2153 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2154 public string PlainString { 2155 get { return plainString_; } 2156 set { 2157 plainString_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 2158 } 2159 } 2160 2161 /// <summary>Field number for the "o2_int32" field.</summary> 2162 public const int O2Int32FieldNumber = 6; 2163 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2164 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2165 public int O2Int32 { 2166 get { return HasO2Int32 ? (int) o2_ : 0; } 2167 set { 2168 o2_ = value; 2169 o2Case_ = O2OneofCase.O2Int32; 2170 } 2171 } 2172 /// <summary>Gets whether the "o2_int32" field is set</summary> 2173 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2174 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2175 public bool HasO2Int32 { 2176 get { return o2Case_ == O2OneofCase.O2Int32; } 2177 } 2178 /// <summary> Clears the value of the oneof if it's currently set to "o2_int32" </summary> 2179 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2180 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearO2Int32()2181 public void ClearO2Int32() { 2182 if (HasO2Int32) { 2183 ClearO2(); 2184 } 2185 } 2186 2187 /// <summary>Field number for the "o2_string" field.</summary> 2188 public const int O2StringFieldNumber = 3; 2189 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2190 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2191 public string O2String { 2192 get { return HasO2String ? (string) o2_ : ""; } 2193 set { 2194 o2_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 2195 o2Case_ = O2OneofCase.O2String; 2196 } 2197 } 2198 /// <summary>Gets whether the "o2_string" field is set</summary> 2199 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2200 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2201 public bool HasO2String { 2202 get { return o2Case_ == O2OneofCase.O2String; } 2203 } 2204 /// <summary> Clears the value of the oneof if it's currently set to "o2_string" </summary> 2205 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2206 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearO2String()2207 public void ClearO2String() { 2208 if (HasO2String) { 2209 ClearO2(); 2210 } 2211 } 2212 2213 private object o1_; 2214 /// <summary>Enum of possible cases for the "o1" oneof.</summary> 2215 public enum O1OneofCase { 2216 None = 0, 2217 O1String = 2, 2218 O1Int32 = 5, 2219 } 2220 private O1OneofCase o1Case_ = O1OneofCase.None; 2221 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2222 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2223 public O1OneofCase O1Case { 2224 get { return o1Case_; } 2225 } 2226 2227 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2228 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearO1()2229 public void ClearO1() { 2230 o1Case_ = O1OneofCase.None; 2231 o1_ = null; 2232 } 2233 2234 private object o2_; 2235 /// <summary>Enum of possible cases for the "o2" oneof.</summary> 2236 public enum O2OneofCase { 2237 None = 0, 2238 O2Int32 = 6, 2239 O2String = 3, 2240 } 2241 private O2OneofCase o2Case_ = O2OneofCase.None; 2242 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2243 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2244 public O2OneofCase O2Case { 2245 get { return o2Case_; } 2246 } 2247 2248 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2249 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearO2()2250 public void ClearO2() { 2251 o2Case_ = O2OneofCase.None; 2252 o2_ = null; 2253 } 2254 2255 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2256 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)2257 public override bool Equals(object other) { 2258 return Equals(other as TestJsonFieldOrdering); 2259 } 2260 2261 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2262 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(TestJsonFieldOrdering other)2263 public bool Equals(TestJsonFieldOrdering other) { 2264 if (ReferenceEquals(other, null)) { 2265 return false; 2266 } 2267 if (ReferenceEquals(other, this)) { 2268 return true; 2269 } 2270 if (PlainInt32 != other.PlainInt32) return false; 2271 if (O1String != other.O1String) return false; 2272 if (O1Int32 != other.O1Int32) return false; 2273 if (PlainString != other.PlainString) return false; 2274 if (O2Int32 != other.O2Int32) return false; 2275 if (O2String != other.O2String) return false; 2276 if (O1Case != other.O1Case) return false; 2277 if (O2Case != other.O2Case) return false; 2278 return Equals(_unknownFields, other._unknownFields); 2279 } 2280 2281 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2282 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()2283 public override int GetHashCode() { 2284 int hash = 1; 2285 if (PlainInt32 != 0) hash ^= PlainInt32.GetHashCode(); 2286 if (HasO1String) hash ^= O1String.GetHashCode(); 2287 if (HasO1Int32) hash ^= O1Int32.GetHashCode(); 2288 if (PlainString.Length != 0) hash ^= PlainString.GetHashCode(); 2289 if (HasO2Int32) hash ^= O2Int32.GetHashCode(); 2290 if (HasO2String) hash ^= O2String.GetHashCode(); 2291 hash ^= (int) o1Case_; 2292 hash ^= (int) o2Case_; 2293 if (_unknownFields != null) { 2294 hash ^= _unknownFields.GetHashCode(); 2295 } 2296 return hash; 2297 } 2298 2299 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2300 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()2301 public override string ToString() { 2302 return pb::JsonFormatter.ToDiagnosticString(this); 2303 } 2304 2305 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2306 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)2307 public void WriteTo(pb::CodedOutputStream output) { 2308 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2309 output.WriteRawMessage(this); 2310 #else 2311 if (PlainString.Length != 0) { 2312 output.WriteRawTag(10); 2313 output.WriteString(PlainString); 2314 } 2315 if (HasO1String) { 2316 output.WriteRawTag(18); 2317 output.WriteString(O1String); 2318 } 2319 if (HasO2String) { 2320 output.WriteRawTag(26); 2321 output.WriteString(O2String); 2322 } 2323 if (PlainInt32 != 0) { 2324 output.WriteRawTag(32); 2325 output.WriteInt32(PlainInt32); 2326 } 2327 if (HasO1Int32) { 2328 output.WriteRawTag(40); 2329 output.WriteInt32(O1Int32); 2330 } 2331 if (HasO2Int32) { 2332 output.WriteRawTag(48); 2333 output.WriteInt32(O2Int32); 2334 } 2335 if (_unknownFields != null) { 2336 _unknownFields.WriteTo(output); 2337 } 2338 #endif 2339 } 2340 2341 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2342 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2343 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)2344 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 2345 if (PlainString.Length != 0) { 2346 output.WriteRawTag(10); 2347 output.WriteString(PlainString); 2348 } 2349 if (HasO1String) { 2350 output.WriteRawTag(18); 2351 output.WriteString(O1String); 2352 } 2353 if (HasO2String) { 2354 output.WriteRawTag(26); 2355 output.WriteString(O2String); 2356 } 2357 if (PlainInt32 != 0) { 2358 output.WriteRawTag(32); 2359 output.WriteInt32(PlainInt32); 2360 } 2361 if (HasO1Int32) { 2362 output.WriteRawTag(40); 2363 output.WriteInt32(O1Int32); 2364 } 2365 if (HasO2Int32) { 2366 output.WriteRawTag(48); 2367 output.WriteInt32(O2Int32); 2368 } 2369 if (_unknownFields != null) { 2370 _unknownFields.WriteTo(ref output); 2371 } 2372 } 2373 #endif 2374 2375 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2376 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()2377 public int CalculateSize() { 2378 int size = 0; 2379 if (PlainInt32 != 0) { 2380 size += 1 + pb::CodedOutputStream.ComputeInt32Size(PlainInt32); 2381 } 2382 if (HasO1String) { 2383 size += 1 + pb::CodedOutputStream.ComputeStringSize(O1String); 2384 } 2385 if (HasO1Int32) { 2386 size += 1 + pb::CodedOutputStream.ComputeInt32Size(O1Int32); 2387 } 2388 if (PlainString.Length != 0) { 2389 size += 1 + pb::CodedOutputStream.ComputeStringSize(PlainString); 2390 } 2391 if (HasO2Int32) { 2392 size += 1 + pb::CodedOutputStream.ComputeInt32Size(O2Int32); 2393 } 2394 if (HasO2String) { 2395 size += 1 + pb::CodedOutputStream.ComputeStringSize(O2String); 2396 } 2397 if (_unknownFields != null) { 2398 size += _unknownFields.CalculateSize(); 2399 } 2400 return size; 2401 } 2402 2403 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2404 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(TestJsonFieldOrdering other)2405 public void MergeFrom(TestJsonFieldOrdering other) { 2406 if (other == null) { 2407 return; 2408 } 2409 if (other.PlainInt32 != 0) { 2410 PlainInt32 = other.PlainInt32; 2411 } 2412 if (other.PlainString.Length != 0) { 2413 PlainString = other.PlainString; 2414 } 2415 switch (other.O1Case) { 2416 case O1OneofCase.O1String: 2417 O1String = other.O1String; 2418 break; 2419 case O1OneofCase.O1Int32: 2420 O1Int32 = other.O1Int32; 2421 break; 2422 } 2423 2424 switch (other.O2Case) { 2425 case O2OneofCase.O2Int32: 2426 O2Int32 = other.O2Int32; 2427 break; 2428 case O2OneofCase.O2String: 2429 O2String = other.O2String; 2430 break; 2431 } 2432 2433 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 2434 } 2435 2436 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2437 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)2438 public void MergeFrom(pb::CodedInputStream input) { 2439 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2440 input.ReadRawMessage(this); 2441 #else 2442 uint tag; 2443 while ((tag = input.ReadTag()) != 0) { 2444 if ((tag & 7) == 4) { 2445 // Abort on any end group tag. 2446 return; 2447 } 2448 switch(tag) { 2449 default: 2450 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 2451 break; 2452 case 10: { 2453 PlainString = input.ReadString(); 2454 break; 2455 } 2456 case 18: { 2457 O1String = input.ReadString(); 2458 break; 2459 } 2460 case 26: { 2461 O2String = input.ReadString(); 2462 break; 2463 } 2464 case 32: { 2465 PlainInt32 = input.ReadInt32(); 2466 break; 2467 } 2468 case 40: { 2469 O1Int32 = input.ReadInt32(); 2470 break; 2471 } 2472 case 48: { 2473 O2Int32 = input.ReadInt32(); 2474 break; 2475 } 2476 } 2477 } 2478 #endif 2479 } 2480 2481 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2482 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2483 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)2484 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 2485 uint tag; 2486 while ((tag = input.ReadTag()) != 0) { 2487 if ((tag & 7) == 4) { 2488 // Abort on any end group tag. 2489 return; 2490 } 2491 switch(tag) { 2492 default: 2493 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 2494 break; 2495 case 10: { 2496 PlainString = input.ReadString(); 2497 break; 2498 } 2499 case 18: { 2500 O1String = input.ReadString(); 2501 break; 2502 } 2503 case 26: { 2504 O2String = input.ReadString(); 2505 break; 2506 } 2507 case 32: { 2508 PlainInt32 = input.ReadInt32(); 2509 break; 2510 } 2511 case 40: { 2512 O1Int32 = input.ReadInt32(); 2513 break; 2514 } 2515 case 48: { 2516 O2Int32 = input.ReadInt32(); 2517 break; 2518 } 2519 } 2520 } 2521 } 2522 #endif 2523 2524 } 2525 2526 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 2527 public sealed partial class TestJsonName : pb::IMessage<TestJsonName> 2528 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2529 , pb::IBufferMessage 2530 #endif 2531 { 2532 private static readonly pb::MessageParser<TestJsonName> _parser = new pb::MessageParser<TestJsonName>(() => new TestJsonName()); 2533 private pb::UnknownFieldSet _unknownFields; 2534 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2535 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2536 public static pb::MessageParser<TestJsonName> Parser { get { return _parser; } } 2537 2538 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2539 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2540 public static pbr::MessageDescriptor Descriptor { 2541 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[7]; } 2542 } 2543 2544 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2545 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2546 pbr::MessageDescriptor pb::IMessage.Descriptor { 2547 get { return Descriptor; } 2548 } 2549 2550 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2551 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] TestJsonName()2552 public TestJsonName() { 2553 OnConstruction(); 2554 } 2555 OnConstruction()2556 partial void OnConstruction(); 2557 2558 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2559 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] TestJsonName(TestJsonName other)2560 public TestJsonName(TestJsonName other) : this() { 2561 name_ = other.name_; 2562 description_ = other.description_; 2563 guid_ = other.guid_; 2564 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 2565 } 2566 2567 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2568 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()2569 public TestJsonName Clone() { 2570 return new TestJsonName(this); 2571 } 2572 2573 /// <summary>Field number for the "name" field.</summary> 2574 public const int NameFieldNumber = 1; 2575 private string name_ = ""; 2576 /// <summary> 2577 /// Message for testing the effects for of the json_name option 2578 /// </summary> 2579 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2580 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2581 public string Name { 2582 get { return name_; } 2583 set { 2584 name_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 2585 } 2586 } 2587 2588 /// <summary>Field number for the "description" field.</summary> 2589 public const int DescriptionFieldNumber = 2; 2590 private string description_ = ""; 2591 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2592 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2593 public string Description { 2594 get { return description_; } 2595 set { 2596 description_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 2597 } 2598 } 2599 2600 /// <summary>Field number for the "guid" field.</summary> 2601 public const int GuidFieldNumber = 3; 2602 private string guid_ = ""; 2603 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2604 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2605 public string Guid { 2606 get { return guid_; } 2607 set { 2608 guid_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 2609 } 2610 } 2611 2612 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2613 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)2614 public override bool Equals(object other) { 2615 return Equals(other as TestJsonName); 2616 } 2617 2618 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2619 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(TestJsonName other)2620 public bool Equals(TestJsonName other) { 2621 if (ReferenceEquals(other, null)) { 2622 return false; 2623 } 2624 if (ReferenceEquals(other, this)) { 2625 return true; 2626 } 2627 if (Name != other.Name) return false; 2628 if (Description != other.Description) return false; 2629 if (Guid != other.Guid) return false; 2630 return Equals(_unknownFields, other._unknownFields); 2631 } 2632 2633 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2634 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()2635 public override int GetHashCode() { 2636 int hash = 1; 2637 if (Name.Length != 0) hash ^= Name.GetHashCode(); 2638 if (Description.Length != 0) hash ^= Description.GetHashCode(); 2639 if (Guid.Length != 0) hash ^= Guid.GetHashCode(); 2640 if (_unknownFields != null) { 2641 hash ^= _unknownFields.GetHashCode(); 2642 } 2643 return hash; 2644 } 2645 2646 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2647 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()2648 public override string ToString() { 2649 return pb::JsonFormatter.ToDiagnosticString(this); 2650 } 2651 2652 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2653 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)2654 public void WriteTo(pb::CodedOutputStream output) { 2655 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2656 output.WriteRawMessage(this); 2657 #else 2658 if (Name.Length != 0) { 2659 output.WriteRawTag(10); 2660 output.WriteString(Name); 2661 } 2662 if (Description.Length != 0) { 2663 output.WriteRawTag(18); 2664 output.WriteString(Description); 2665 } 2666 if (Guid.Length != 0) { 2667 output.WriteRawTag(26); 2668 output.WriteString(Guid); 2669 } 2670 if (_unknownFields != null) { 2671 _unknownFields.WriteTo(output); 2672 } 2673 #endif 2674 } 2675 2676 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2677 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2678 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)2679 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 2680 if (Name.Length != 0) { 2681 output.WriteRawTag(10); 2682 output.WriteString(Name); 2683 } 2684 if (Description.Length != 0) { 2685 output.WriteRawTag(18); 2686 output.WriteString(Description); 2687 } 2688 if (Guid.Length != 0) { 2689 output.WriteRawTag(26); 2690 output.WriteString(Guid); 2691 } 2692 if (_unknownFields != null) { 2693 _unknownFields.WriteTo(ref output); 2694 } 2695 } 2696 #endif 2697 2698 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2699 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()2700 public int CalculateSize() { 2701 int size = 0; 2702 if (Name.Length != 0) { 2703 size += 1 + pb::CodedOutputStream.ComputeStringSize(Name); 2704 } 2705 if (Description.Length != 0) { 2706 size += 1 + pb::CodedOutputStream.ComputeStringSize(Description); 2707 } 2708 if (Guid.Length != 0) { 2709 size += 1 + pb::CodedOutputStream.ComputeStringSize(Guid); 2710 } 2711 if (_unknownFields != null) { 2712 size += _unknownFields.CalculateSize(); 2713 } 2714 return size; 2715 } 2716 2717 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2718 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(TestJsonName other)2719 public void MergeFrom(TestJsonName other) { 2720 if (other == null) { 2721 return; 2722 } 2723 if (other.Name.Length != 0) { 2724 Name = other.Name; 2725 } 2726 if (other.Description.Length != 0) { 2727 Description = other.Description; 2728 } 2729 if (other.Guid.Length != 0) { 2730 Guid = other.Guid; 2731 } 2732 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 2733 } 2734 2735 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2736 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)2737 public void MergeFrom(pb::CodedInputStream input) { 2738 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2739 input.ReadRawMessage(this); 2740 #else 2741 uint tag; 2742 while ((tag = input.ReadTag()) != 0) { 2743 if ((tag & 7) == 4) { 2744 // Abort on any end group tag. 2745 return; 2746 } 2747 switch(tag) { 2748 default: 2749 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 2750 break; 2751 case 10: { 2752 Name = input.ReadString(); 2753 break; 2754 } 2755 case 18: { 2756 Description = input.ReadString(); 2757 break; 2758 } 2759 case 26: { 2760 Guid = input.ReadString(); 2761 break; 2762 } 2763 } 2764 } 2765 #endif 2766 } 2767 2768 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2769 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2770 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)2771 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 2772 uint tag; 2773 while ((tag = input.ReadTag()) != 0) { 2774 if ((tag & 7) == 4) { 2775 // Abort on any end group tag. 2776 return; 2777 } 2778 switch(tag) { 2779 default: 2780 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 2781 break; 2782 case 10: { 2783 Name = input.ReadString(); 2784 break; 2785 } 2786 case 18: { 2787 Description = input.ReadString(); 2788 break; 2789 } 2790 case 26: { 2791 Guid = input.ReadString(); 2792 break; 2793 } 2794 } 2795 } 2796 } 2797 #endif 2798 2799 } 2800 2801 /// <summary> 2802 /// Issue 3200: When merging two messages which use the same 2803 /// oneof case, which is itself a message type, the submessages should 2804 /// be merged. 2805 /// </summary> 2806 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 2807 public sealed partial class OneofMerging : pb::IMessage<OneofMerging> 2808 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2809 , pb::IBufferMessage 2810 #endif 2811 { 2812 private static readonly pb::MessageParser<OneofMerging> _parser = new pb::MessageParser<OneofMerging>(() => new OneofMerging()); 2813 private pb::UnknownFieldSet _unknownFields; 2814 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2815 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2816 public static pb::MessageParser<OneofMerging> Parser { get { return _parser; } } 2817 2818 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2819 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2820 public static pbr::MessageDescriptor Descriptor { 2821 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[8]; } 2822 } 2823 2824 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2825 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2826 pbr::MessageDescriptor pb::IMessage.Descriptor { 2827 get { return Descriptor; } 2828 } 2829 2830 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2831 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] OneofMerging()2832 public OneofMerging() { 2833 OnConstruction(); 2834 } 2835 OnConstruction()2836 partial void OnConstruction(); 2837 2838 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2839 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] OneofMerging(OneofMerging other)2840 public OneofMerging(OneofMerging other) : this() { 2841 switch (other.ValueCase) { 2842 case ValueOneofCase.Text: 2843 Text = other.Text; 2844 break; 2845 case ValueOneofCase.Nested: 2846 Nested = other.Nested.Clone(); 2847 break; 2848 } 2849 2850 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 2851 } 2852 2853 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2854 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()2855 public OneofMerging Clone() { 2856 return new OneofMerging(this); 2857 } 2858 2859 /// <summary>Field number for the "text" field.</summary> 2860 public const int TextFieldNumber = 1; 2861 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2862 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2863 public string Text { 2864 get { return HasText ? (string) value_ : ""; } 2865 set { 2866 value_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 2867 valueCase_ = ValueOneofCase.Text; 2868 } 2869 } 2870 /// <summary>Gets whether the "text" field is set</summary> 2871 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2872 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2873 public bool HasText { 2874 get { return valueCase_ == ValueOneofCase.Text; } 2875 } 2876 /// <summary> Clears the value of the oneof if it's currently set to "text" </summary> 2877 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2878 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearText()2879 public void ClearText() { 2880 if (HasText) { 2881 ClearValue(); 2882 } 2883 } 2884 2885 /// <summary>Field number for the "nested" field.</summary> 2886 public const int NestedFieldNumber = 2; 2887 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2888 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2889 public global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested Nested { 2890 get { return valueCase_ == ValueOneofCase.Nested ? (global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested) value_ : null; } 2891 set { 2892 value_ = value; 2893 valueCase_ = value == null ? ValueOneofCase.None : ValueOneofCase.Nested; 2894 } 2895 } 2896 2897 private object value_; 2898 /// <summary>Enum of possible cases for the "value" oneof.</summary> 2899 public enum ValueOneofCase { 2900 None = 0, 2901 Text = 1, 2902 Nested = 2, 2903 } 2904 private ValueOneofCase valueCase_ = ValueOneofCase.None; 2905 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2906 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 2907 public ValueOneofCase ValueCase { 2908 get { return valueCase_; } 2909 } 2910 2911 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2912 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearValue()2913 public void ClearValue() { 2914 valueCase_ = ValueOneofCase.None; 2915 value_ = null; 2916 } 2917 2918 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2919 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)2920 public override bool Equals(object other) { 2921 return Equals(other as OneofMerging); 2922 } 2923 2924 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2925 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(OneofMerging other)2926 public bool Equals(OneofMerging other) { 2927 if (ReferenceEquals(other, null)) { 2928 return false; 2929 } 2930 if (ReferenceEquals(other, this)) { 2931 return true; 2932 } 2933 if (Text != other.Text) return false; 2934 if (!object.Equals(Nested, other.Nested)) return false; 2935 if (ValueCase != other.ValueCase) return false; 2936 return Equals(_unknownFields, other._unknownFields); 2937 } 2938 2939 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2940 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()2941 public override int GetHashCode() { 2942 int hash = 1; 2943 if (HasText) hash ^= Text.GetHashCode(); 2944 if (valueCase_ == ValueOneofCase.Nested) hash ^= Nested.GetHashCode(); 2945 hash ^= (int) valueCase_; 2946 if (_unknownFields != null) { 2947 hash ^= _unknownFields.GetHashCode(); 2948 } 2949 return hash; 2950 } 2951 2952 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2953 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()2954 public override string ToString() { 2955 return pb::JsonFormatter.ToDiagnosticString(this); 2956 } 2957 2958 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2959 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)2960 public void WriteTo(pb::CodedOutputStream output) { 2961 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2962 output.WriteRawMessage(this); 2963 #else 2964 if (HasText) { 2965 output.WriteRawTag(10); 2966 output.WriteString(Text); 2967 } 2968 if (valueCase_ == ValueOneofCase.Nested) { 2969 output.WriteRawTag(18); 2970 output.WriteMessage(Nested); 2971 } 2972 if (_unknownFields != null) { 2973 _unknownFields.WriteTo(output); 2974 } 2975 #endif 2976 } 2977 2978 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 2979 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2980 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)2981 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 2982 if (HasText) { 2983 output.WriteRawTag(10); 2984 output.WriteString(Text); 2985 } 2986 if (valueCase_ == ValueOneofCase.Nested) { 2987 output.WriteRawTag(18); 2988 output.WriteMessage(Nested); 2989 } 2990 if (_unknownFields != null) { 2991 _unknownFields.WriteTo(ref output); 2992 } 2993 } 2994 #endif 2995 2996 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 2997 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()2998 public int CalculateSize() { 2999 int size = 0; 3000 if (HasText) { 3001 size += 1 + pb::CodedOutputStream.ComputeStringSize(Text); 3002 } 3003 if (valueCase_ == ValueOneofCase.Nested) { 3004 size += 1 + pb::CodedOutputStream.ComputeMessageSize(Nested); 3005 } 3006 if (_unknownFields != null) { 3007 size += _unknownFields.CalculateSize(); 3008 } 3009 return size; 3010 } 3011 3012 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3013 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(OneofMerging other)3014 public void MergeFrom(OneofMerging other) { 3015 if (other == null) { 3016 return; 3017 } 3018 switch (other.ValueCase) { 3019 case ValueOneofCase.Text: 3020 Text = other.Text; 3021 break; 3022 case ValueOneofCase.Nested: 3023 if (Nested == null) { 3024 Nested = new global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested(); 3025 } 3026 Nested.MergeFrom(other.Nested); 3027 break; 3028 } 3029 3030 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 3031 } 3032 3033 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3034 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)3035 public void MergeFrom(pb::CodedInputStream input) { 3036 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3037 input.ReadRawMessage(this); 3038 #else 3039 uint tag; 3040 while ((tag = input.ReadTag()) != 0) { 3041 if ((tag & 7) == 4) { 3042 // Abort on any end group tag. 3043 return; 3044 } 3045 switch(tag) { 3046 default: 3047 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 3048 break; 3049 case 10: { 3050 Text = input.ReadString(); 3051 break; 3052 } 3053 case 18: { 3054 global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested subBuilder = new global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested(); 3055 if (valueCase_ == ValueOneofCase.Nested) { 3056 subBuilder.MergeFrom(Nested); 3057 } 3058 input.ReadMessage(subBuilder); 3059 Nested = subBuilder; 3060 break; 3061 } 3062 } 3063 } 3064 #endif 3065 } 3066 3067 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3068 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3069 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)3070 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 3071 uint tag; 3072 while ((tag = input.ReadTag()) != 0) { 3073 if ((tag & 7) == 4) { 3074 // Abort on any end group tag. 3075 return; 3076 } 3077 switch(tag) { 3078 default: 3079 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 3080 break; 3081 case 10: { 3082 Text = input.ReadString(); 3083 break; 3084 } 3085 case 18: { 3086 global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested subBuilder = new global::UnitTest.Issues.TestProtos.OneofMerging.Types.Nested(); 3087 if (valueCase_ == ValueOneofCase.Nested) { 3088 subBuilder.MergeFrom(Nested); 3089 } 3090 input.ReadMessage(subBuilder); 3091 Nested = subBuilder; 3092 break; 3093 } 3094 } 3095 } 3096 } 3097 #endif 3098 3099 #region Nested types 3100 /// <summary>Container for nested types declared in the OneofMerging message type.</summary> 3101 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3102 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3103 public static partial class Types { 3104 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 3105 public sealed partial class Nested : pb::IMessage<Nested> 3106 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3107 , pb::IBufferMessage 3108 #endif 3109 { 3110 private static readonly pb::MessageParser<Nested> _parser = new pb::MessageParser<Nested>(() => new Nested()); 3111 private pb::UnknownFieldSet _unknownFields; 3112 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3113 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3114 public static pb::MessageParser<Nested> Parser { get { return _parser; } } 3115 3116 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3117 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3118 public static pbr::MessageDescriptor Descriptor { 3119 get { return global::UnitTest.Issues.TestProtos.OneofMerging.Descriptor.NestedTypes[0]; } 3120 } 3121 3122 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3123 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3124 pbr::MessageDescriptor pb::IMessage.Descriptor { 3125 get { return Descriptor; } 3126 } 3127 3128 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3129 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Nested()3130 public Nested() { 3131 OnConstruction(); 3132 } 3133 OnConstruction()3134 partial void OnConstruction(); 3135 3136 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3137 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Nested(Nested other)3138 public Nested(Nested other) : this() { 3139 x_ = other.x_; 3140 y_ = other.y_; 3141 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 3142 } 3143 3144 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3145 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()3146 public Nested Clone() { 3147 return new Nested(this); 3148 } 3149 3150 /// <summary>Field number for the "x" field.</summary> 3151 public const int XFieldNumber = 1; 3152 private int x_; 3153 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3154 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3155 public int X { 3156 get { return x_; } 3157 set { 3158 x_ = value; 3159 } 3160 } 3161 3162 /// <summary>Field number for the "y" field.</summary> 3163 public const int YFieldNumber = 2; 3164 private int y_; 3165 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3166 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3167 public int Y { 3168 get { return y_; } 3169 set { 3170 y_ = value; 3171 } 3172 } 3173 3174 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3175 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)3176 public override bool Equals(object other) { 3177 return Equals(other as Nested); 3178 } 3179 3180 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3181 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(Nested other)3182 public bool Equals(Nested other) { 3183 if (ReferenceEquals(other, null)) { 3184 return false; 3185 } 3186 if (ReferenceEquals(other, this)) { 3187 return true; 3188 } 3189 if (X != other.X) return false; 3190 if (Y != other.Y) return false; 3191 return Equals(_unknownFields, other._unknownFields); 3192 } 3193 3194 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3195 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()3196 public override int GetHashCode() { 3197 int hash = 1; 3198 if (X != 0) hash ^= X.GetHashCode(); 3199 if (Y != 0) hash ^= Y.GetHashCode(); 3200 if (_unknownFields != null) { 3201 hash ^= _unknownFields.GetHashCode(); 3202 } 3203 return hash; 3204 } 3205 3206 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3207 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()3208 public override string ToString() { 3209 return pb::JsonFormatter.ToDiagnosticString(this); 3210 } 3211 3212 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3213 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)3214 public void WriteTo(pb::CodedOutputStream output) { 3215 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3216 output.WriteRawMessage(this); 3217 #else 3218 if (X != 0) { 3219 output.WriteRawTag(8); 3220 output.WriteInt32(X); 3221 } 3222 if (Y != 0) { 3223 output.WriteRawTag(16); 3224 output.WriteInt32(Y); 3225 } 3226 if (_unknownFields != null) { 3227 _unknownFields.WriteTo(output); 3228 } 3229 #endif 3230 } 3231 3232 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3233 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3234 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)3235 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 3236 if (X != 0) { 3237 output.WriteRawTag(8); 3238 output.WriteInt32(X); 3239 } 3240 if (Y != 0) { 3241 output.WriteRawTag(16); 3242 output.WriteInt32(Y); 3243 } 3244 if (_unknownFields != null) { 3245 _unknownFields.WriteTo(ref output); 3246 } 3247 } 3248 #endif 3249 3250 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3251 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()3252 public int CalculateSize() { 3253 int size = 0; 3254 if (X != 0) { 3255 size += 1 + pb::CodedOutputStream.ComputeInt32Size(X); 3256 } 3257 if (Y != 0) { 3258 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Y); 3259 } 3260 if (_unknownFields != null) { 3261 size += _unknownFields.CalculateSize(); 3262 } 3263 return size; 3264 } 3265 3266 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3267 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(Nested other)3268 public void MergeFrom(Nested other) { 3269 if (other == null) { 3270 return; 3271 } 3272 if (other.X != 0) { 3273 X = other.X; 3274 } 3275 if (other.Y != 0) { 3276 Y = other.Y; 3277 } 3278 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 3279 } 3280 3281 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3282 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)3283 public void MergeFrom(pb::CodedInputStream input) { 3284 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3285 input.ReadRawMessage(this); 3286 #else 3287 uint tag; 3288 while ((tag = input.ReadTag()) != 0) { 3289 if ((tag & 7) == 4) { 3290 // Abort on any end group tag. 3291 return; 3292 } 3293 switch(tag) { 3294 default: 3295 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 3296 break; 3297 case 8: { 3298 X = input.ReadInt32(); 3299 break; 3300 } 3301 case 16: { 3302 Y = input.ReadInt32(); 3303 break; 3304 } 3305 } 3306 } 3307 #endif 3308 } 3309 3310 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3311 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3312 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)3313 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 3314 uint tag; 3315 while ((tag = input.ReadTag()) != 0) { 3316 if ((tag & 7) == 4) { 3317 // Abort on any end group tag. 3318 return; 3319 } 3320 switch(tag) { 3321 default: 3322 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 3323 break; 3324 case 8: { 3325 X = input.ReadInt32(); 3326 break; 3327 } 3328 case 16: { 3329 Y = input.ReadInt32(); 3330 break; 3331 } 3332 } 3333 } 3334 } 3335 #endif 3336 3337 } 3338 3339 } 3340 #endregion 3341 3342 } 3343 3344 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 3345 public sealed partial class NullValueOutsideStruct : pb::IMessage<NullValueOutsideStruct> 3346 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3347 , pb::IBufferMessage 3348 #endif 3349 { 3350 private static readonly pb::MessageParser<NullValueOutsideStruct> _parser = new pb::MessageParser<NullValueOutsideStruct>(() => new NullValueOutsideStruct()); 3351 private pb::UnknownFieldSet _unknownFields; 3352 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3353 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3354 public static pb::MessageParser<NullValueOutsideStruct> Parser { get { return _parser; } } 3355 3356 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3357 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3358 public static pbr::MessageDescriptor Descriptor { 3359 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[9]; } 3360 } 3361 3362 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3363 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3364 pbr::MessageDescriptor pb::IMessage.Descriptor { 3365 get { return Descriptor; } 3366 } 3367 3368 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3369 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NullValueOutsideStruct()3370 public NullValueOutsideStruct() { 3371 OnConstruction(); 3372 } 3373 OnConstruction()3374 partial void OnConstruction(); 3375 3376 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3377 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NullValueOutsideStruct(NullValueOutsideStruct other)3378 public NullValueOutsideStruct(NullValueOutsideStruct other) : this() { 3379 switch (other.ValueCase) { 3380 case ValueOneofCase.StringValue: 3381 StringValue = other.StringValue; 3382 break; 3383 case ValueOneofCase.NullValue: 3384 NullValue = other.NullValue; 3385 break; 3386 } 3387 3388 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 3389 } 3390 3391 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3392 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()3393 public NullValueOutsideStruct Clone() { 3394 return new NullValueOutsideStruct(this); 3395 } 3396 3397 /// <summary>Field number for the "string_value" field.</summary> 3398 public const int StringValueFieldNumber = 1; 3399 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3400 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3401 public string StringValue { 3402 get { return HasStringValue ? (string) value_ : ""; } 3403 set { 3404 value_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 3405 valueCase_ = ValueOneofCase.StringValue; 3406 } 3407 } 3408 /// <summary>Gets whether the "string_value" field is set</summary> 3409 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3410 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3411 public bool HasStringValue { 3412 get { return valueCase_ == ValueOneofCase.StringValue; } 3413 } 3414 /// <summary> Clears the value of the oneof if it's currently set to "string_value" </summary> 3415 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3416 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearStringValue()3417 public void ClearStringValue() { 3418 if (HasStringValue) { 3419 ClearValue(); 3420 } 3421 } 3422 3423 /// <summary>Field number for the "null_value" field.</summary> 3424 public const int NullValueFieldNumber = 2; 3425 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3426 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3427 public global::Google.Protobuf.WellKnownTypes.NullValue NullValue { 3428 get { return HasNullValue ? (global::Google.Protobuf.WellKnownTypes.NullValue) value_ : global::Google.Protobuf.WellKnownTypes.NullValue.NullValue; } 3429 set { 3430 value_ = value; 3431 valueCase_ = ValueOneofCase.NullValue; 3432 } 3433 } 3434 /// <summary>Gets whether the "null_value" field is set</summary> 3435 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3436 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3437 public bool HasNullValue { 3438 get { return valueCase_ == ValueOneofCase.NullValue; } 3439 } 3440 /// <summary> Clears the value of the oneof if it's currently set to "null_value" </summary> 3441 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3442 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearNullValue()3443 public void ClearNullValue() { 3444 if (HasNullValue) { 3445 ClearValue(); 3446 } 3447 } 3448 3449 private object value_; 3450 /// <summary>Enum of possible cases for the "value" oneof.</summary> 3451 public enum ValueOneofCase { 3452 None = 0, 3453 StringValue = 1, 3454 NullValue = 2, 3455 } 3456 private ValueOneofCase valueCase_ = ValueOneofCase.None; 3457 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3458 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3459 public ValueOneofCase ValueCase { 3460 get { return valueCase_; } 3461 } 3462 3463 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3464 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearValue()3465 public void ClearValue() { 3466 valueCase_ = ValueOneofCase.None; 3467 value_ = null; 3468 } 3469 3470 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3471 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)3472 public override bool Equals(object other) { 3473 return Equals(other as NullValueOutsideStruct); 3474 } 3475 3476 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3477 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(NullValueOutsideStruct other)3478 public bool Equals(NullValueOutsideStruct other) { 3479 if (ReferenceEquals(other, null)) { 3480 return false; 3481 } 3482 if (ReferenceEquals(other, this)) { 3483 return true; 3484 } 3485 if (StringValue != other.StringValue) return false; 3486 if (NullValue != other.NullValue) return false; 3487 if (ValueCase != other.ValueCase) return false; 3488 return Equals(_unknownFields, other._unknownFields); 3489 } 3490 3491 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3492 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()3493 public override int GetHashCode() { 3494 int hash = 1; 3495 if (HasStringValue) hash ^= StringValue.GetHashCode(); 3496 if (HasNullValue) hash ^= NullValue.GetHashCode(); 3497 hash ^= (int) valueCase_; 3498 if (_unknownFields != null) { 3499 hash ^= _unknownFields.GetHashCode(); 3500 } 3501 return hash; 3502 } 3503 3504 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3505 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()3506 public override string ToString() { 3507 return pb::JsonFormatter.ToDiagnosticString(this); 3508 } 3509 3510 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3511 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)3512 public void WriteTo(pb::CodedOutputStream output) { 3513 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3514 output.WriteRawMessage(this); 3515 #else 3516 if (HasStringValue) { 3517 output.WriteRawTag(10); 3518 output.WriteString(StringValue); 3519 } 3520 if (HasNullValue) { 3521 output.WriteRawTag(16); 3522 output.WriteEnum((int) NullValue); 3523 } 3524 if (_unknownFields != null) { 3525 _unknownFields.WriteTo(output); 3526 } 3527 #endif 3528 } 3529 3530 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3531 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3532 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)3533 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 3534 if (HasStringValue) { 3535 output.WriteRawTag(10); 3536 output.WriteString(StringValue); 3537 } 3538 if (HasNullValue) { 3539 output.WriteRawTag(16); 3540 output.WriteEnum((int) NullValue); 3541 } 3542 if (_unknownFields != null) { 3543 _unknownFields.WriteTo(ref output); 3544 } 3545 } 3546 #endif 3547 3548 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3549 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()3550 public int CalculateSize() { 3551 int size = 0; 3552 if (HasStringValue) { 3553 size += 1 + pb::CodedOutputStream.ComputeStringSize(StringValue); 3554 } 3555 if (HasNullValue) { 3556 size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) NullValue); 3557 } 3558 if (_unknownFields != null) { 3559 size += _unknownFields.CalculateSize(); 3560 } 3561 return size; 3562 } 3563 3564 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3565 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(NullValueOutsideStruct other)3566 public void MergeFrom(NullValueOutsideStruct other) { 3567 if (other == null) { 3568 return; 3569 } 3570 switch (other.ValueCase) { 3571 case ValueOneofCase.StringValue: 3572 StringValue = other.StringValue; 3573 break; 3574 case ValueOneofCase.NullValue: 3575 NullValue = other.NullValue; 3576 break; 3577 } 3578 3579 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 3580 } 3581 3582 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3583 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)3584 public void MergeFrom(pb::CodedInputStream input) { 3585 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3586 input.ReadRawMessage(this); 3587 #else 3588 uint tag; 3589 while ((tag = input.ReadTag()) != 0) { 3590 if ((tag & 7) == 4) { 3591 // Abort on any end group tag. 3592 return; 3593 } 3594 switch(tag) { 3595 default: 3596 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 3597 break; 3598 case 10: { 3599 StringValue = input.ReadString(); 3600 break; 3601 } 3602 case 16: { 3603 value_ = input.ReadEnum(); 3604 valueCase_ = ValueOneofCase.NullValue; 3605 break; 3606 } 3607 } 3608 } 3609 #endif 3610 } 3611 3612 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3613 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3614 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)3615 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 3616 uint tag; 3617 while ((tag = input.ReadTag()) != 0) { 3618 if ((tag & 7) == 4) { 3619 // Abort on any end group tag. 3620 return; 3621 } 3622 switch(tag) { 3623 default: 3624 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 3625 break; 3626 case 10: { 3627 StringValue = input.ReadString(); 3628 break; 3629 } 3630 case 16: { 3631 value_ = input.ReadEnum(); 3632 valueCase_ = ValueOneofCase.NullValue; 3633 break; 3634 } 3635 } 3636 } 3637 } 3638 #endif 3639 3640 } 3641 3642 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 3643 public sealed partial class NullValueNotInOneof : pb::IMessage<NullValueNotInOneof> 3644 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3645 , pb::IBufferMessage 3646 #endif 3647 { 3648 private static readonly pb::MessageParser<NullValueNotInOneof> _parser = new pb::MessageParser<NullValueNotInOneof>(() => new NullValueNotInOneof()); 3649 private pb::UnknownFieldSet _unknownFields; 3650 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3651 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3652 public static pb::MessageParser<NullValueNotInOneof> Parser { get { return _parser; } } 3653 3654 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3655 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3656 public static pbr::MessageDescriptor Descriptor { 3657 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[10]; } 3658 } 3659 3660 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3661 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3662 pbr::MessageDescriptor pb::IMessage.Descriptor { 3663 get { return Descriptor; } 3664 } 3665 3666 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3667 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NullValueNotInOneof()3668 public NullValueNotInOneof() { 3669 OnConstruction(); 3670 } 3671 OnConstruction()3672 partial void OnConstruction(); 3673 3674 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3675 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] NullValueNotInOneof(NullValueNotInOneof other)3676 public NullValueNotInOneof(NullValueNotInOneof other) : this() { 3677 nullValue_ = other.nullValue_; 3678 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 3679 } 3680 3681 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3682 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()3683 public NullValueNotInOneof Clone() { 3684 return new NullValueNotInOneof(this); 3685 } 3686 3687 /// <summary>Field number for the "null_value" field.</summary> 3688 public const int NullValueFieldNumber = 2; 3689 private global::Google.Protobuf.WellKnownTypes.NullValue nullValue_ = global::Google.Protobuf.WellKnownTypes.NullValue.NullValue; 3690 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3691 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3692 public global::Google.Protobuf.WellKnownTypes.NullValue NullValue { 3693 get { return nullValue_; } 3694 set { 3695 nullValue_ = value; 3696 } 3697 } 3698 3699 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3700 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)3701 public override bool Equals(object other) { 3702 return Equals(other as NullValueNotInOneof); 3703 } 3704 3705 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3706 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(NullValueNotInOneof other)3707 public bool Equals(NullValueNotInOneof other) { 3708 if (ReferenceEquals(other, null)) { 3709 return false; 3710 } 3711 if (ReferenceEquals(other, this)) { 3712 return true; 3713 } 3714 if (NullValue != other.NullValue) return false; 3715 return Equals(_unknownFields, other._unknownFields); 3716 } 3717 3718 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3719 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()3720 public override int GetHashCode() { 3721 int hash = 1; 3722 if (NullValue != global::Google.Protobuf.WellKnownTypes.NullValue.NullValue) hash ^= NullValue.GetHashCode(); 3723 if (_unknownFields != null) { 3724 hash ^= _unknownFields.GetHashCode(); 3725 } 3726 return hash; 3727 } 3728 3729 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3730 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()3731 public override string ToString() { 3732 return pb::JsonFormatter.ToDiagnosticString(this); 3733 } 3734 3735 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3736 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)3737 public void WriteTo(pb::CodedOutputStream output) { 3738 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3739 output.WriteRawMessage(this); 3740 #else 3741 if (NullValue != global::Google.Protobuf.WellKnownTypes.NullValue.NullValue) { 3742 output.WriteRawTag(16); 3743 output.WriteEnum((int) NullValue); 3744 } 3745 if (_unknownFields != null) { 3746 _unknownFields.WriteTo(output); 3747 } 3748 #endif 3749 } 3750 3751 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3752 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3753 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)3754 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 3755 if (NullValue != global::Google.Protobuf.WellKnownTypes.NullValue.NullValue) { 3756 output.WriteRawTag(16); 3757 output.WriteEnum((int) NullValue); 3758 } 3759 if (_unknownFields != null) { 3760 _unknownFields.WriteTo(ref output); 3761 } 3762 } 3763 #endif 3764 3765 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3766 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()3767 public int CalculateSize() { 3768 int size = 0; 3769 if (NullValue != global::Google.Protobuf.WellKnownTypes.NullValue.NullValue) { 3770 size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) NullValue); 3771 } 3772 if (_unknownFields != null) { 3773 size += _unknownFields.CalculateSize(); 3774 } 3775 return size; 3776 } 3777 3778 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3779 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(NullValueNotInOneof other)3780 public void MergeFrom(NullValueNotInOneof other) { 3781 if (other == null) { 3782 return; 3783 } 3784 if (other.NullValue != global::Google.Protobuf.WellKnownTypes.NullValue.NullValue) { 3785 NullValue = other.NullValue; 3786 } 3787 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 3788 } 3789 3790 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3791 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)3792 public void MergeFrom(pb::CodedInputStream input) { 3793 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3794 input.ReadRawMessage(this); 3795 #else 3796 uint tag; 3797 while ((tag = input.ReadTag()) != 0) { 3798 if ((tag & 7) == 4) { 3799 // Abort on any end group tag. 3800 return; 3801 } 3802 switch(tag) { 3803 default: 3804 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 3805 break; 3806 case 16: { 3807 NullValue = (global::Google.Protobuf.WellKnownTypes.NullValue) input.ReadEnum(); 3808 break; 3809 } 3810 } 3811 } 3812 #endif 3813 } 3814 3815 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3816 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3817 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)3818 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 3819 uint tag; 3820 while ((tag = input.ReadTag()) != 0) { 3821 if ((tag & 7) == 4) { 3822 // Abort on any end group tag. 3823 return; 3824 } 3825 switch(tag) { 3826 default: 3827 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 3828 break; 3829 case 16: { 3830 NullValue = (global::Google.Protobuf.WellKnownTypes.NullValue) input.ReadEnum(); 3831 break; 3832 } 3833 } 3834 } 3835 } 3836 #endif 3837 3838 } 3839 3840 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 3841 public sealed partial class MixedRegularAndOptional : pb::IMessage<MixedRegularAndOptional> 3842 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3843 , pb::IBufferMessage 3844 #endif 3845 { 3846 private static readonly pb::MessageParser<MixedRegularAndOptional> _parser = new pb::MessageParser<MixedRegularAndOptional>(() => new MixedRegularAndOptional()); 3847 private pb::UnknownFieldSet _unknownFields; 3848 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3849 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3850 public static pb::MessageParser<MixedRegularAndOptional> Parser { get { return _parser; } } 3851 3852 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3853 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3854 public static pbr::MessageDescriptor Descriptor { 3855 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[11]; } 3856 } 3857 3858 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3859 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3860 pbr::MessageDescriptor pb::IMessage.Descriptor { 3861 get { return Descriptor; } 3862 } 3863 3864 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3865 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MixedRegularAndOptional()3866 public MixedRegularAndOptional() { 3867 OnConstruction(); 3868 } 3869 OnConstruction()3870 partial void OnConstruction(); 3871 3872 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3873 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MixedRegularAndOptional(MixedRegularAndOptional other)3874 public MixedRegularAndOptional(MixedRegularAndOptional other) : this() { 3875 regularField_ = other.regularField_; 3876 optionalField_ = other.optionalField_; 3877 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 3878 } 3879 3880 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3881 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()3882 public MixedRegularAndOptional Clone() { 3883 return new MixedRegularAndOptional(this); 3884 } 3885 3886 /// <summary>Field number for the "regular_field" field.</summary> 3887 public const int RegularFieldFieldNumber = 1; 3888 private string regularField_ = ""; 3889 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3890 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3891 public string RegularField { 3892 get { return regularField_; } 3893 set { 3894 regularField_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 3895 } 3896 } 3897 3898 /// <summary>Field number for the "optional_field" field.</summary> 3899 public const int OptionalFieldFieldNumber = 2; 3900 private readonly static string OptionalFieldDefaultValue = ""; 3901 3902 private string optionalField_; 3903 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3904 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3905 public string OptionalField { 3906 get { return optionalField_ ?? OptionalFieldDefaultValue; } 3907 set { 3908 optionalField_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 3909 } 3910 } 3911 /// <summary>Gets whether the "optional_field" field is set</summary> 3912 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3913 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 3914 public bool HasOptionalField { 3915 get { return optionalField_ != null; } 3916 } 3917 /// <summary>Clears the value of the "optional_field" field</summary> 3918 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3919 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearOptionalField()3920 public void ClearOptionalField() { 3921 optionalField_ = null; 3922 } 3923 3924 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3925 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)3926 public override bool Equals(object other) { 3927 return Equals(other as MixedRegularAndOptional); 3928 } 3929 3930 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3931 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(MixedRegularAndOptional other)3932 public bool Equals(MixedRegularAndOptional other) { 3933 if (ReferenceEquals(other, null)) { 3934 return false; 3935 } 3936 if (ReferenceEquals(other, this)) { 3937 return true; 3938 } 3939 if (RegularField != other.RegularField) return false; 3940 if (OptionalField != other.OptionalField) return false; 3941 return Equals(_unknownFields, other._unknownFields); 3942 } 3943 3944 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3945 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()3946 public override int GetHashCode() { 3947 int hash = 1; 3948 if (RegularField.Length != 0) hash ^= RegularField.GetHashCode(); 3949 if (HasOptionalField) hash ^= OptionalField.GetHashCode(); 3950 if (_unknownFields != null) { 3951 hash ^= _unknownFields.GetHashCode(); 3952 } 3953 return hash; 3954 } 3955 3956 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3957 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()3958 public override string ToString() { 3959 return pb::JsonFormatter.ToDiagnosticString(this); 3960 } 3961 3962 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3963 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)3964 public void WriteTo(pb::CodedOutputStream output) { 3965 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3966 output.WriteRawMessage(this); 3967 #else 3968 if (RegularField.Length != 0) { 3969 output.WriteRawTag(10); 3970 output.WriteString(RegularField); 3971 } 3972 if (HasOptionalField) { 3973 output.WriteRawTag(18); 3974 output.WriteString(OptionalField); 3975 } 3976 if (_unknownFields != null) { 3977 _unknownFields.WriteTo(output); 3978 } 3979 #endif 3980 } 3981 3982 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 3983 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 3984 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)3985 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 3986 if (RegularField.Length != 0) { 3987 output.WriteRawTag(10); 3988 output.WriteString(RegularField); 3989 } 3990 if (HasOptionalField) { 3991 output.WriteRawTag(18); 3992 output.WriteString(OptionalField); 3993 } 3994 if (_unknownFields != null) { 3995 _unknownFields.WriteTo(ref output); 3996 } 3997 } 3998 #endif 3999 4000 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4001 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()4002 public int CalculateSize() { 4003 int size = 0; 4004 if (RegularField.Length != 0) { 4005 size += 1 + pb::CodedOutputStream.ComputeStringSize(RegularField); 4006 } 4007 if (HasOptionalField) { 4008 size += 1 + pb::CodedOutputStream.ComputeStringSize(OptionalField); 4009 } 4010 if (_unknownFields != null) { 4011 size += _unknownFields.CalculateSize(); 4012 } 4013 return size; 4014 } 4015 4016 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4017 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(MixedRegularAndOptional other)4018 public void MergeFrom(MixedRegularAndOptional other) { 4019 if (other == null) { 4020 return; 4021 } 4022 if (other.RegularField.Length != 0) { 4023 RegularField = other.RegularField; 4024 } 4025 if (other.HasOptionalField) { 4026 OptionalField = other.OptionalField; 4027 } 4028 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 4029 } 4030 4031 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4032 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)4033 public void MergeFrom(pb::CodedInputStream input) { 4034 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4035 input.ReadRawMessage(this); 4036 #else 4037 uint tag; 4038 while ((tag = input.ReadTag()) != 0) { 4039 if ((tag & 7) == 4) { 4040 // Abort on any end group tag. 4041 return; 4042 } 4043 switch(tag) { 4044 default: 4045 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 4046 break; 4047 case 10: { 4048 RegularField = input.ReadString(); 4049 break; 4050 } 4051 case 18: { 4052 OptionalField = input.ReadString(); 4053 break; 4054 } 4055 } 4056 } 4057 #endif 4058 } 4059 4060 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4061 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4062 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)4063 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 4064 uint tag; 4065 while ((tag = input.ReadTag()) != 0) { 4066 if ((tag & 7) == 4) { 4067 // Abort on any end group tag. 4068 return; 4069 } 4070 switch(tag) { 4071 default: 4072 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 4073 break; 4074 case 10: { 4075 RegularField = input.ReadString(); 4076 break; 4077 } 4078 case 18: { 4079 OptionalField = input.ReadString(); 4080 break; 4081 } 4082 } 4083 } 4084 } 4085 #endif 4086 4087 } 4088 4089 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 4090 public sealed partial class OneofWithNoneField : pb::IMessage<OneofWithNoneField> 4091 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4092 , pb::IBufferMessage 4093 #endif 4094 { 4095 private static readonly pb::MessageParser<OneofWithNoneField> _parser = new pb::MessageParser<OneofWithNoneField>(() => new OneofWithNoneField()); 4096 private pb::UnknownFieldSet _unknownFields; 4097 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4098 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4099 public static pb::MessageParser<OneofWithNoneField> Parser { get { return _parser; } } 4100 4101 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4102 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4103 public static pbr::MessageDescriptor Descriptor { 4104 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[12]; } 4105 } 4106 4107 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4108 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4109 pbr::MessageDescriptor pb::IMessage.Descriptor { 4110 get { return Descriptor; } 4111 } 4112 4113 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4114 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] OneofWithNoneField()4115 public OneofWithNoneField() { 4116 OnConstruction(); 4117 } 4118 OnConstruction()4119 partial void OnConstruction(); 4120 4121 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4122 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] OneofWithNoneField(OneofWithNoneField other)4123 public OneofWithNoneField(OneofWithNoneField other) : this() { 4124 switch (other.TestCase) { 4125 case TestOneofCase.X: 4126 X = other.X; 4127 break; 4128 case TestOneofCase.None_: 4129 None = other.None; 4130 break; 4131 } 4132 4133 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 4134 } 4135 4136 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4137 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()4138 public OneofWithNoneField Clone() { 4139 return new OneofWithNoneField(this); 4140 } 4141 4142 /// <summary>Field number for the "x" field.</summary> 4143 public const int XFieldNumber = 1; 4144 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4145 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4146 public string X { 4147 get { return HasX ? (string) test_ : ""; } 4148 set { 4149 test_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 4150 testCase_ = TestOneofCase.X; 4151 } 4152 } 4153 /// <summary>Gets whether the "x" field is set</summary> 4154 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4155 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4156 public bool HasX { 4157 get { return testCase_ == TestOneofCase.X; } 4158 } 4159 /// <summary> Clears the value of the oneof if it's currently set to "x" </summary> 4160 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4161 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearX()4162 public void ClearX() { 4163 if (HasX) { 4164 ClearTest(); 4165 } 4166 } 4167 4168 /// <summary>Field number for the "none" field.</summary> 4169 public const int NoneFieldNumber = 2; 4170 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4171 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4172 public string None { 4173 get { return HasNone ? (string) test_ : ""; } 4174 set { 4175 test_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 4176 testCase_ = TestOneofCase.None_; 4177 } 4178 } 4179 /// <summary>Gets whether the "none" field is set</summary> 4180 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4181 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4182 public bool HasNone { 4183 get { return testCase_ == TestOneofCase.None_; } 4184 } 4185 /// <summary> Clears the value of the oneof if it's currently set to "none" </summary> 4186 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4187 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearNone()4188 public void ClearNone() { 4189 if (HasNone) { 4190 ClearTest(); 4191 } 4192 } 4193 4194 private object test_; 4195 /// <summary>Enum of possible cases for the "test" oneof.</summary> 4196 public enum TestOneofCase { 4197 None = 0, 4198 X = 1, 4199 None_ = 2, 4200 } 4201 private TestOneofCase testCase_ = TestOneofCase.None; 4202 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4203 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4204 public TestOneofCase TestCase { 4205 get { return testCase_; } 4206 } 4207 4208 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4209 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearTest()4210 public void ClearTest() { 4211 testCase_ = TestOneofCase.None; 4212 test_ = null; 4213 } 4214 4215 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4216 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)4217 public override bool Equals(object other) { 4218 return Equals(other as OneofWithNoneField); 4219 } 4220 4221 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4222 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(OneofWithNoneField other)4223 public bool Equals(OneofWithNoneField other) { 4224 if (ReferenceEquals(other, null)) { 4225 return false; 4226 } 4227 if (ReferenceEquals(other, this)) { 4228 return true; 4229 } 4230 if (X != other.X) return false; 4231 if (None != other.None) return false; 4232 if (TestCase != other.TestCase) return false; 4233 return Equals(_unknownFields, other._unknownFields); 4234 } 4235 4236 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4237 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()4238 public override int GetHashCode() { 4239 int hash = 1; 4240 if (HasX) hash ^= X.GetHashCode(); 4241 if (HasNone) hash ^= None.GetHashCode(); 4242 hash ^= (int) testCase_; 4243 if (_unknownFields != null) { 4244 hash ^= _unknownFields.GetHashCode(); 4245 } 4246 return hash; 4247 } 4248 4249 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4250 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()4251 public override string ToString() { 4252 return pb::JsonFormatter.ToDiagnosticString(this); 4253 } 4254 4255 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4256 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)4257 public void WriteTo(pb::CodedOutputStream output) { 4258 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4259 output.WriteRawMessage(this); 4260 #else 4261 if (HasX) { 4262 output.WriteRawTag(10); 4263 output.WriteString(X); 4264 } 4265 if (HasNone) { 4266 output.WriteRawTag(18); 4267 output.WriteString(None); 4268 } 4269 if (_unknownFields != null) { 4270 _unknownFields.WriteTo(output); 4271 } 4272 #endif 4273 } 4274 4275 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4276 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4277 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)4278 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 4279 if (HasX) { 4280 output.WriteRawTag(10); 4281 output.WriteString(X); 4282 } 4283 if (HasNone) { 4284 output.WriteRawTag(18); 4285 output.WriteString(None); 4286 } 4287 if (_unknownFields != null) { 4288 _unknownFields.WriteTo(ref output); 4289 } 4290 } 4291 #endif 4292 4293 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4294 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()4295 public int CalculateSize() { 4296 int size = 0; 4297 if (HasX) { 4298 size += 1 + pb::CodedOutputStream.ComputeStringSize(X); 4299 } 4300 if (HasNone) { 4301 size += 1 + pb::CodedOutputStream.ComputeStringSize(None); 4302 } 4303 if (_unknownFields != null) { 4304 size += _unknownFields.CalculateSize(); 4305 } 4306 return size; 4307 } 4308 4309 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4310 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(OneofWithNoneField other)4311 public void MergeFrom(OneofWithNoneField other) { 4312 if (other == null) { 4313 return; 4314 } 4315 switch (other.TestCase) { 4316 case TestOneofCase.X: 4317 X = other.X; 4318 break; 4319 case TestOneofCase.None_: 4320 None = other.None; 4321 break; 4322 } 4323 4324 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 4325 } 4326 4327 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4328 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)4329 public void MergeFrom(pb::CodedInputStream input) { 4330 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4331 input.ReadRawMessage(this); 4332 #else 4333 uint tag; 4334 while ((tag = input.ReadTag()) != 0) { 4335 if ((tag & 7) == 4) { 4336 // Abort on any end group tag. 4337 return; 4338 } 4339 switch(tag) { 4340 default: 4341 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 4342 break; 4343 case 10: { 4344 X = input.ReadString(); 4345 break; 4346 } 4347 case 18: { 4348 None = input.ReadString(); 4349 break; 4350 } 4351 } 4352 } 4353 #endif 4354 } 4355 4356 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4357 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4358 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)4359 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 4360 uint tag; 4361 while ((tag = input.ReadTag()) != 0) { 4362 if ((tag & 7) == 4) { 4363 // Abort on any end group tag. 4364 return; 4365 } 4366 switch(tag) { 4367 default: 4368 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 4369 break; 4370 case 10: { 4371 X = input.ReadString(); 4372 break; 4373 } 4374 case 18: { 4375 None = input.ReadString(); 4376 break; 4377 } 4378 } 4379 } 4380 } 4381 #endif 4382 4383 } 4384 4385 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 4386 public sealed partial class OneofWithNoneName : pb::IMessage<OneofWithNoneName> 4387 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4388 , pb::IBufferMessage 4389 #endif 4390 { 4391 private static readonly pb::MessageParser<OneofWithNoneName> _parser = new pb::MessageParser<OneofWithNoneName>(() => new OneofWithNoneName()); 4392 private pb::UnknownFieldSet _unknownFields; 4393 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4394 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4395 public static pb::MessageParser<OneofWithNoneName> Parser { get { return _parser; } } 4396 4397 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4398 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4399 public static pbr::MessageDescriptor Descriptor { 4400 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[13]; } 4401 } 4402 4403 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4404 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4405 pbr::MessageDescriptor pb::IMessage.Descriptor { 4406 get { return Descriptor; } 4407 } 4408 4409 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4410 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] OneofWithNoneName()4411 public OneofWithNoneName() { 4412 OnConstruction(); 4413 } 4414 OnConstruction()4415 partial void OnConstruction(); 4416 4417 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4418 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] OneofWithNoneName(OneofWithNoneName other)4419 public OneofWithNoneName(OneofWithNoneName other) : this() { 4420 switch (other.NoneCase) { 4421 case NoneOneofCase.X: 4422 X = other.X; 4423 break; 4424 case NoneOneofCase.Y: 4425 Y = other.Y; 4426 break; 4427 } 4428 4429 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 4430 } 4431 4432 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4433 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()4434 public OneofWithNoneName Clone() { 4435 return new OneofWithNoneName(this); 4436 } 4437 4438 /// <summary>Field number for the "x" field.</summary> 4439 public const int XFieldNumber = 1; 4440 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4441 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4442 public string X { 4443 get { return HasX ? (string) none_ : ""; } 4444 set { 4445 none_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 4446 noneCase_ = NoneOneofCase.X; 4447 } 4448 } 4449 /// <summary>Gets whether the "x" field is set</summary> 4450 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4451 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4452 public bool HasX { 4453 get { return noneCase_ == NoneOneofCase.X; } 4454 } 4455 /// <summary> Clears the value of the oneof if it's currently set to "x" </summary> 4456 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4457 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearX()4458 public void ClearX() { 4459 if (HasX) { 4460 ClearNone(); 4461 } 4462 } 4463 4464 /// <summary>Field number for the "y" field.</summary> 4465 public const int YFieldNumber = 2; 4466 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4467 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4468 public string Y { 4469 get { return HasY ? (string) none_ : ""; } 4470 set { 4471 none_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); 4472 noneCase_ = NoneOneofCase.Y; 4473 } 4474 } 4475 /// <summary>Gets whether the "y" field is set</summary> 4476 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4477 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4478 public bool HasY { 4479 get { return noneCase_ == NoneOneofCase.Y; } 4480 } 4481 /// <summary> Clears the value of the oneof if it's currently set to "y" </summary> 4482 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4483 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearY()4484 public void ClearY() { 4485 if (HasY) { 4486 ClearNone(); 4487 } 4488 } 4489 4490 private object none_; 4491 /// <summary>Enum of possible cases for the "none" oneof.</summary> 4492 public enum NoneOneofCase { 4493 None = 0, 4494 X = 1, 4495 Y = 2, 4496 } 4497 private NoneOneofCase noneCase_ = NoneOneofCase.None; 4498 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4499 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4500 public NoneOneofCase NoneCase { 4501 get { return noneCase_; } 4502 } 4503 4504 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4505 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ClearNone()4506 public void ClearNone() { 4507 noneCase_ = NoneOneofCase.None; 4508 none_ = null; 4509 } 4510 4511 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4512 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)4513 public override bool Equals(object other) { 4514 return Equals(other as OneofWithNoneName); 4515 } 4516 4517 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4518 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(OneofWithNoneName other)4519 public bool Equals(OneofWithNoneName other) { 4520 if (ReferenceEquals(other, null)) { 4521 return false; 4522 } 4523 if (ReferenceEquals(other, this)) { 4524 return true; 4525 } 4526 if (X != other.X) return false; 4527 if (Y != other.Y) return false; 4528 if (NoneCase != other.NoneCase) return false; 4529 return Equals(_unknownFields, other._unknownFields); 4530 } 4531 4532 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4533 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()4534 public override int GetHashCode() { 4535 int hash = 1; 4536 if (HasX) hash ^= X.GetHashCode(); 4537 if (HasY) hash ^= Y.GetHashCode(); 4538 hash ^= (int) noneCase_; 4539 if (_unknownFields != null) { 4540 hash ^= _unknownFields.GetHashCode(); 4541 } 4542 return hash; 4543 } 4544 4545 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4546 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()4547 public override string ToString() { 4548 return pb::JsonFormatter.ToDiagnosticString(this); 4549 } 4550 4551 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4552 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)4553 public void WriteTo(pb::CodedOutputStream output) { 4554 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4555 output.WriteRawMessage(this); 4556 #else 4557 if (HasX) { 4558 output.WriteRawTag(10); 4559 output.WriteString(X); 4560 } 4561 if (HasY) { 4562 output.WriteRawTag(18); 4563 output.WriteString(Y); 4564 } 4565 if (_unknownFields != null) { 4566 _unknownFields.WriteTo(output); 4567 } 4568 #endif 4569 } 4570 4571 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4572 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4573 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)4574 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 4575 if (HasX) { 4576 output.WriteRawTag(10); 4577 output.WriteString(X); 4578 } 4579 if (HasY) { 4580 output.WriteRawTag(18); 4581 output.WriteString(Y); 4582 } 4583 if (_unknownFields != null) { 4584 _unknownFields.WriteTo(ref output); 4585 } 4586 } 4587 #endif 4588 4589 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4590 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()4591 public int CalculateSize() { 4592 int size = 0; 4593 if (HasX) { 4594 size += 1 + pb::CodedOutputStream.ComputeStringSize(X); 4595 } 4596 if (HasY) { 4597 size += 1 + pb::CodedOutputStream.ComputeStringSize(Y); 4598 } 4599 if (_unknownFields != null) { 4600 size += _unknownFields.CalculateSize(); 4601 } 4602 return size; 4603 } 4604 4605 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4606 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(OneofWithNoneName other)4607 public void MergeFrom(OneofWithNoneName other) { 4608 if (other == null) { 4609 return; 4610 } 4611 switch (other.NoneCase) { 4612 case NoneOneofCase.X: 4613 X = other.X; 4614 break; 4615 case NoneOneofCase.Y: 4616 Y = other.Y; 4617 break; 4618 } 4619 4620 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 4621 } 4622 4623 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4624 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)4625 public void MergeFrom(pb::CodedInputStream input) { 4626 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4627 input.ReadRawMessage(this); 4628 #else 4629 uint tag; 4630 while ((tag = input.ReadTag()) != 0) { 4631 if ((tag & 7) == 4) { 4632 // Abort on any end group tag. 4633 return; 4634 } 4635 switch(tag) { 4636 default: 4637 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 4638 break; 4639 case 10: { 4640 X = input.ReadString(); 4641 break; 4642 } 4643 case 18: { 4644 Y = input.ReadString(); 4645 break; 4646 } 4647 } 4648 } 4649 #endif 4650 } 4651 4652 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4653 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4654 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)4655 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 4656 uint tag; 4657 while ((tag = input.ReadTag()) != 0) { 4658 if ((tag & 7) == 4) { 4659 // Abort on any end group tag. 4660 return; 4661 } 4662 switch(tag) { 4663 default: 4664 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 4665 break; 4666 case 10: { 4667 X = input.ReadString(); 4668 break; 4669 } 4670 case 18: { 4671 Y = input.ReadString(); 4672 break; 4673 } 4674 } 4675 } 4676 } 4677 #endif 4678 4679 } 4680 4681 /// <summary> 4682 /// Issue 8810 4683 /// </summary> 4684 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 4685 public sealed partial class DisambiguateCommonMembers : pb::IMessage<DisambiguateCommonMembers> 4686 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4687 , pb::IBufferMessage 4688 #endif 4689 { 4690 private static readonly pb::MessageParser<DisambiguateCommonMembers> _parser = new pb::MessageParser<DisambiguateCommonMembers>(() => new DisambiguateCommonMembers()); 4691 private pb::UnknownFieldSet _unknownFields; 4692 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4693 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4694 public static pb::MessageParser<DisambiguateCommonMembers> Parser { get { return _parser; } } 4695 4696 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4697 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4698 public static pbr::MessageDescriptor Descriptor { 4699 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[14]; } 4700 } 4701 4702 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4703 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4704 pbr::MessageDescriptor pb::IMessage.Descriptor { 4705 get { return Descriptor; } 4706 } 4707 4708 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4709 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] DisambiguateCommonMembers()4710 public DisambiguateCommonMembers() { 4711 OnConstruction(); 4712 } 4713 OnConstruction()4714 partial void OnConstruction(); 4715 4716 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4717 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] DisambiguateCommonMembers(DisambiguateCommonMembers other)4718 public DisambiguateCommonMembers(DisambiguateCommonMembers other) : this() { 4719 disambiguateCommonMembers_ = other.disambiguateCommonMembers_; 4720 types_ = other.types_; 4721 descriptor_ = other.descriptor_; 4722 equals_ = other.equals_; 4723 toString_ = other.toString_; 4724 getHashCode_ = other.getHashCode_; 4725 writeTo_ = other.writeTo_; 4726 clone_ = other.clone_; 4727 calculateSize_ = other.calculateSize_; 4728 mergeFrom_ = other.mergeFrom_; 4729 onConstruction_ = other.onConstruction_; 4730 parser_ = other.parser_; 4731 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 4732 } 4733 4734 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4735 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()4736 public DisambiguateCommonMembers Clone() { 4737 return new DisambiguateCommonMembers(this); 4738 } 4739 4740 /// <summary>Field number for the "disambiguate_common_members" field.</summary> 4741 public const int DisambiguateCommonMembers_FieldNumber = 1; 4742 private int disambiguateCommonMembers_; 4743 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4744 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4745 public int DisambiguateCommonMembers_ { 4746 get { return disambiguateCommonMembers_; } 4747 set { 4748 disambiguateCommonMembers_ = value; 4749 } 4750 } 4751 4752 /// <summary>Field number for the "types" field.</summary> 4753 public const int Types_FieldNumber = 2; 4754 private int types_; 4755 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4756 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4757 public int Types_ { 4758 get { return types_; } 4759 set { 4760 types_ = value; 4761 } 4762 } 4763 4764 /// <summary>Field number for the "descriptor" field.</summary> 4765 public const int Descriptor_FieldNumber = 3; 4766 private int descriptor_; 4767 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4768 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4769 public int Descriptor_ { 4770 get { return descriptor_; } 4771 set { 4772 descriptor_ = value; 4773 } 4774 } 4775 4776 /// <summary>Field number for the "equals" field.</summary> 4777 public const int Equals_FieldNumber = 4; 4778 private int equals_; 4779 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4780 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4781 public int Equals_ { 4782 get { return equals_; } 4783 set { 4784 equals_ = value; 4785 } 4786 } 4787 4788 /// <summary>Field number for the "to_string" field.</summary> 4789 public const int ToString_FieldNumber = 5; 4790 private int toString_; 4791 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4792 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4793 public int ToString_ { 4794 get { return toString_; } 4795 set { 4796 toString_ = value; 4797 } 4798 } 4799 4800 /// <summary>Field number for the "get_hash_code" field.</summary> 4801 public const int GetHashCode_FieldNumber = 6; 4802 private int getHashCode_; 4803 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4804 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4805 public int GetHashCode_ { 4806 get { return getHashCode_; } 4807 set { 4808 getHashCode_ = value; 4809 } 4810 } 4811 4812 /// <summary>Field number for the "write_to" field.</summary> 4813 public const int WriteTo_FieldNumber = 7; 4814 private int writeTo_; 4815 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4816 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4817 public int WriteTo_ { 4818 get { return writeTo_; } 4819 set { 4820 writeTo_ = value; 4821 } 4822 } 4823 4824 /// <summary>Field number for the "clone" field.</summary> 4825 public const int Clone_FieldNumber = 8; 4826 private int clone_; 4827 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4828 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4829 public int Clone_ { 4830 get { return clone_; } 4831 set { 4832 clone_ = value; 4833 } 4834 } 4835 4836 /// <summary>Field number for the "calculate_size" field.</summary> 4837 public const int CalculateSize_FieldNumber = 9; 4838 private int calculateSize_; 4839 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4840 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4841 public int CalculateSize_ { 4842 get { return calculateSize_; } 4843 set { 4844 calculateSize_ = value; 4845 } 4846 } 4847 4848 /// <summary>Field number for the "merge_from" field.</summary> 4849 public const int MergeFrom_FieldNumber = 10; 4850 private int mergeFrom_; 4851 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4852 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4853 public int MergeFrom_ { 4854 get { return mergeFrom_; } 4855 set { 4856 mergeFrom_ = value; 4857 } 4858 } 4859 4860 /// <summary>Field number for the "on_construction" field.</summary> 4861 public const int OnConstruction_FieldNumber = 11; 4862 private int onConstruction_; 4863 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4864 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4865 public int OnConstruction_ { 4866 get { return onConstruction_; } 4867 set { 4868 onConstruction_ = value; 4869 } 4870 } 4871 4872 /// <summary>Field number for the "parser" field.</summary> 4873 public const int Parser_FieldNumber = 12; 4874 private int parser_; 4875 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4876 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 4877 public int Parser_ { 4878 get { return parser_; } 4879 set { 4880 parser_ = value; 4881 } 4882 } 4883 4884 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4885 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)4886 public override bool Equals(object other) { 4887 return Equals(other as DisambiguateCommonMembers); 4888 } 4889 4890 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4891 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(DisambiguateCommonMembers other)4892 public bool Equals(DisambiguateCommonMembers other) { 4893 if (ReferenceEquals(other, null)) { 4894 return false; 4895 } 4896 if (ReferenceEquals(other, this)) { 4897 return true; 4898 } 4899 if (DisambiguateCommonMembers_ != other.DisambiguateCommonMembers_) return false; 4900 if (Types_ != other.Types_) return false; 4901 if (Descriptor_ != other.Descriptor_) return false; 4902 if (Equals_ != other.Equals_) return false; 4903 if (ToString_ != other.ToString_) return false; 4904 if (GetHashCode_ != other.GetHashCode_) return false; 4905 if (WriteTo_ != other.WriteTo_) return false; 4906 if (Clone_ != other.Clone_) return false; 4907 if (CalculateSize_ != other.CalculateSize_) return false; 4908 if (MergeFrom_ != other.MergeFrom_) return false; 4909 if (OnConstruction_ != other.OnConstruction_) return false; 4910 if (Parser_ != other.Parser_) return false; 4911 return Equals(_unknownFields, other._unknownFields); 4912 } 4913 4914 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4915 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()4916 public override int GetHashCode() { 4917 int hash = 1; 4918 if (DisambiguateCommonMembers_ != 0) hash ^= DisambiguateCommonMembers_.GetHashCode(); 4919 if (Types_ != 0) hash ^= Types_.GetHashCode(); 4920 if (Descriptor_ != 0) hash ^= Descriptor_.GetHashCode(); 4921 if (Equals_ != 0) hash ^= Equals_.GetHashCode(); 4922 if (ToString_ != 0) hash ^= ToString_.GetHashCode(); 4923 if (GetHashCode_ != 0) hash ^= GetHashCode_.GetHashCode(); 4924 if (WriteTo_ != 0) hash ^= WriteTo_.GetHashCode(); 4925 if (Clone_ != 0) hash ^= Clone_.GetHashCode(); 4926 if (CalculateSize_ != 0) hash ^= CalculateSize_.GetHashCode(); 4927 if (MergeFrom_ != 0) hash ^= MergeFrom_.GetHashCode(); 4928 if (OnConstruction_ != 0) hash ^= OnConstruction_.GetHashCode(); 4929 if (Parser_ != 0) hash ^= Parser_.GetHashCode(); 4930 if (_unknownFields != null) { 4931 hash ^= _unknownFields.GetHashCode(); 4932 } 4933 return hash; 4934 } 4935 4936 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4937 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()4938 public override string ToString() { 4939 return pb::JsonFormatter.ToDiagnosticString(this); 4940 } 4941 4942 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 4943 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)4944 public void WriteTo(pb::CodedOutputStream output) { 4945 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 4946 output.WriteRawMessage(this); 4947 #else 4948 if (DisambiguateCommonMembers_ != 0) { 4949 output.WriteRawTag(8); 4950 output.WriteInt32(DisambiguateCommonMembers_); 4951 } 4952 if (Types_ != 0) { 4953 output.WriteRawTag(16); 4954 output.WriteInt32(Types_); 4955 } 4956 if (Descriptor_ != 0) { 4957 output.WriteRawTag(24); 4958 output.WriteInt32(Descriptor_); 4959 } 4960 if (Equals_ != 0) { 4961 output.WriteRawTag(32); 4962 output.WriteInt32(Equals_); 4963 } 4964 if (ToString_ != 0) { 4965 output.WriteRawTag(40); 4966 output.WriteInt32(ToString_); 4967 } 4968 if (GetHashCode_ != 0) { 4969 output.WriteRawTag(48); 4970 output.WriteInt32(GetHashCode_); 4971 } 4972 if (WriteTo_ != 0) { 4973 output.WriteRawTag(56); 4974 output.WriteInt32(WriteTo_); 4975 } 4976 if (Clone_ != 0) { 4977 output.WriteRawTag(64); 4978 output.WriteInt32(Clone_); 4979 } 4980 if (CalculateSize_ != 0) { 4981 output.WriteRawTag(72); 4982 output.WriteInt32(CalculateSize_); 4983 } 4984 if (MergeFrom_ != 0) { 4985 output.WriteRawTag(80); 4986 output.WriteInt32(MergeFrom_); 4987 } 4988 if (OnConstruction_ != 0) { 4989 output.WriteRawTag(88); 4990 output.WriteInt32(OnConstruction_); 4991 } 4992 if (Parser_ != 0) { 4993 output.WriteRawTag(96); 4994 output.WriteInt32(Parser_); 4995 } 4996 if (_unknownFields != null) { 4997 _unknownFields.WriteTo(output); 4998 } 4999 #endif 5000 } 5001 5002 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5003 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5004 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)5005 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 5006 if (DisambiguateCommonMembers_ != 0) { 5007 output.WriteRawTag(8); 5008 output.WriteInt32(DisambiguateCommonMembers_); 5009 } 5010 if (Types_ != 0) { 5011 output.WriteRawTag(16); 5012 output.WriteInt32(Types_); 5013 } 5014 if (Descriptor_ != 0) { 5015 output.WriteRawTag(24); 5016 output.WriteInt32(Descriptor_); 5017 } 5018 if (Equals_ != 0) { 5019 output.WriteRawTag(32); 5020 output.WriteInt32(Equals_); 5021 } 5022 if (ToString_ != 0) { 5023 output.WriteRawTag(40); 5024 output.WriteInt32(ToString_); 5025 } 5026 if (GetHashCode_ != 0) { 5027 output.WriteRawTag(48); 5028 output.WriteInt32(GetHashCode_); 5029 } 5030 if (WriteTo_ != 0) { 5031 output.WriteRawTag(56); 5032 output.WriteInt32(WriteTo_); 5033 } 5034 if (Clone_ != 0) { 5035 output.WriteRawTag(64); 5036 output.WriteInt32(Clone_); 5037 } 5038 if (CalculateSize_ != 0) { 5039 output.WriteRawTag(72); 5040 output.WriteInt32(CalculateSize_); 5041 } 5042 if (MergeFrom_ != 0) { 5043 output.WriteRawTag(80); 5044 output.WriteInt32(MergeFrom_); 5045 } 5046 if (OnConstruction_ != 0) { 5047 output.WriteRawTag(88); 5048 output.WriteInt32(OnConstruction_); 5049 } 5050 if (Parser_ != 0) { 5051 output.WriteRawTag(96); 5052 output.WriteInt32(Parser_); 5053 } 5054 if (_unknownFields != null) { 5055 _unknownFields.WriteTo(ref output); 5056 } 5057 } 5058 #endif 5059 5060 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5061 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()5062 public int CalculateSize() { 5063 int size = 0; 5064 if (DisambiguateCommonMembers_ != 0) { 5065 size += 1 + pb::CodedOutputStream.ComputeInt32Size(DisambiguateCommonMembers_); 5066 } 5067 if (Types_ != 0) { 5068 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Types_); 5069 } 5070 if (Descriptor_ != 0) { 5071 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Descriptor_); 5072 } 5073 if (Equals_ != 0) { 5074 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Equals_); 5075 } 5076 if (ToString_ != 0) { 5077 size += 1 + pb::CodedOutputStream.ComputeInt32Size(ToString_); 5078 } 5079 if (GetHashCode_ != 0) { 5080 size += 1 + pb::CodedOutputStream.ComputeInt32Size(GetHashCode_); 5081 } 5082 if (WriteTo_ != 0) { 5083 size += 1 + pb::CodedOutputStream.ComputeInt32Size(WriteTo_); 5084 } 5085 if (Clone_ != 0) { 5086 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Clone_); 5087 } 5088 if (CalculateSize_ != 0) { 5089 size += 1 + pb::CodedOutputStream.ComputeInt32Size(CalculateSize_); 5090 } 5091 if (MergeFrom_ != 0) { 5092 size += 1 + pb::CodedOutputStream.ComputeInt32Size(MergeFrom_); 5093 } 5094 if (OnConstruction_ != 0) { 5095 size += 1 + pb::CodedOutputStream.ComputeInt32Size(OnConstruction_); 5096 } 5097 if (Parser_ != 0) { 5098 size += 1 + pb::CodedOutputStream.ComputeInt32Size(Parser_); 5099 } 5100 if (_unknownFields != null) { 5101 size += _unknownFields.CalculateSize(); 5102 } 5103 return size; 5104 } 5105 5106 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5107 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(DisambiguateCommonMembers other)5108 public void MergeFrom(DisambiguateCommonMembers other) { 5109 if (other == null) { 5110 return; 5111 } 5112 if (other.DisambiguateCommonMembers_ != 0) { 5113 DisambiguateCommonMembers_ = other.DisambiguateCommonMembers_; 5114 } 5115 if (other.Types_ != 0) { 5116 Types_ = other.Types_; 5117 } 5118 if (other.Descriptor_ != 0) { 5119 Descriptor_ = other.Descriptor_; 5120 } 5121 if (other.Equals_ != 0) { 5122 Equals_ = other.Equals_; 5123 } 5124 if (other.ToString_ != 0) { 5125 ToString_ = other.ToString_; 5126 } 5127 if (other.GetHashCode_ != 0) { 5128 GetHashCode_ = other.GetHashCode_; 5129 } 5130 if (other.WriteTo_ != 0) { 5131 WriteTo_ = other.WriteTo_; 5132 } 5133 if (other.Clone_ != 0) { 5134 Clone_ = other.Clone_; 5135 } 5136 if (other.CalculateSize_ != 0) { 5137 CalculateSize_ = other.CalculateSize_; 5138 } 5139 if (other.MergeFrom_ != 0) { 5140 MergeFrom_ = other.MergeFrom_; 5141 } 5142 if (other.OnConstruction_ != 0) { 5143 OnConstruction_ = other.OnConstruction_; 5144 } 5145 if (other.Parser_ != 0) { 5146 Parser_ = other.Parser_; 5147 } 5148 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 5149 } 5150 5151 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5152 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)5153 public void MergeFrom(pb::CodedInputStream input) { 5154 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5155 input.ReadRawMessage(this); 5156 #else 5157 uint tag; 5158 while ((tag = input.ReadTag()) != 0) { 5159 if ((tag & 7) == 4) { 5160 // Abort on any end group tag. 5161 return; 5162 } 5163 switch(tag) { 5164 default: 5165 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 5166 break; 5167 case 8: { 5168 DisambiguateCommonMembers_ = input.ReadInt32(); 5169 break; 5170 } 5171 case 16: { 5172 Types_ = input.ReadInt32(); 5173 break; 5174 } 5175 case 24: { 5176 Descriptor_ = input.ReadInt32(); 5177 break; 5178 } 5179 case 32: { 5180 Equals_ = input.ReadInt32(); 5181 break; 5182 } 5183 case 40: { 5184 ToString_ = input.ReadInt32(); 5185 break; 5186 } 5187 case 48: { 5188 GetHashCode_ = input.ReadInt32(); 5189 break; 5190 } 5191 case 56: { 5192 WriteTo_ = input.ReadInt32(); 5193 break; 5194 } 5195 case 64: { 5196 Clone_ = input.ReadInt32(); 5197 break; 5198 } 5199 case 72: { 5200 CalculateSize_ = input.ReadInt32(); 5201 break; 5202 } 5203 case 80: { 5204 MergeFrom_ = input.ReadInt32(); 5205 break; 5206 } 5207 case 88: { 5208 OnConstruction_ = input.ReadInt32(); 5209 break; 5210 } 5211 case 96: { 5212 Parser_ = input.ReadInt32(); 5213 break; 5214 } 5215 } 5216 } 5217 #endif 5218 } 5219 5220 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5221 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5222 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)5223 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 5224 uint tag; 5225 while ((tag = input.ReadTag()) != 0) { 5226 if ((tag & 7) == 4) { 5227 // Abort on any end group tag. 5228 return; 5229 } 5230 switch(tag) { 5231 default: 5232 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 5233 break; 5234 case 8: { 5235 DisambiguateCommonMembers_ = input.ReadInt32(); 5236 break; 5237 } 5238 case 16: { 5239 Types_ = input.ReadInt32(); 5240 break; 5241 } 5242 case 24: { 5243 Descriptor_ = input.ReadInt32(); 5244 break; 5245 } 5246 case 32: { 5247 Equals_ = input.ReadInt32(); 5248 break; 5249 } 5250 case 40: { 5251 ToString_ = input.ReadInt32(); 5252 break; 5253 } 5254 case 48: { 5255 GetHashCode_ = input.ReadInt32(); 5256 break; 5257 } 5258 case 56: { 5259 WriteTo_ = input.ReadInt32(); 5260 break; 5261 } 5262 case 64: { 5263 Clone_ = input.ReadInt32(); 5264 break; 5265 } 5266 case 72: { 5267 CalculateSize_ = input.ReadInt32(); 5268 break; 5269 } 5270 case 80: { 5271 MergeFrom_ = input.ReadInt32(); 5272 break; 5273 } 5274 case 88: { 5275 OnConstruction_ = input.ReadInt32(); 5276 break; 5277 } 5278 case 96: { 5279 Parser_ = input.ReadInt32(); 5280 break; 5281 } 5282 } 5283 } 5284 } 5285 #endif 5286 5287 } 5288 5289 [global::System.Diagnostics.DebuggerDisplayAttribute("{ToString(),nq}")] 5290 public sealed partial class Issue11987Message : pb::IMessage<Issue11987Message> 5291 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5292 , pb::IBufferMessage 5293 #endif 5294 { 5295 private static readonly pb::MessageParser<Issue11987Message> _parser = new pb::MessageParser<Issue11987Message>(() => new Issue11987Message()); 5296 private pb::UnknownFieldSet _unknownFields; 5297 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5298 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 5299 public static pb::MessageParser<Issue11987Message> Parser { get { return _parser; } } 5300 5301 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5302 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 5303 public static pbr::MessageDescriptor Descriptor { 5304 get { return global::UnitTest.Issues.TestProtos.UnittestIssuesReflection.Descriptor.MessageTypes[15]; } 5305 } 5306 5307 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5308 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 5309 pbr::MessageDescriptor pb::IMessage.Descriptor { 5310 get { return Descriptor; } 5311 } 5312 5313 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5314 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Issue11987Message()5315 public Issue11987Message() { 5316 OnConstruction(); 5317 } 5318 OnConstruction()5319 partial void OnConstruction(); 5320 5321 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5322 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Issue11987Message(Issue11987Message other)5323 public Issue11987Message(Issue11987Message other) : this() { 5324 a_ = other.a_; 5325 b_ = other.b_; 5326 c_ = other.c_; 5327 _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); 5328 } 5329 5330 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5331 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Clone()5332 public Issue11987Message Clone() { 5333 return new Issue11987Message(this); 5334 } 5335 5336 /// <summary>Field number for the "a" field.</summary> 5337 public const int AFieldNumber = 1; 5338 private int a_; 5339 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5340 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 5341 public int A { 5342 get { return a_; } 5343 set { 5344 a_ = value; 5345 } 5346 } 5347 5348 /// <summary>Field number for the "b" field.</summary> 5349 public const int BFieldNumber = 2; 5350 private int b_; 5351 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5352 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 5353 public int B { 5354 get { return b_; } 5355 set { 5356 b_ = value; 5357 } 5358 } 5359 5360 /// <summary>Field number for the "c" field.</summary> 5361 public const int CFieldNumber = 3; 5362 private int c_; 5363 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5364 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] 5365 public int C { 5366 get { return c_; } 5367 set { 5368 c_ = value; 5369 } 5370 } 5371 5372 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5373 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(object other)5374 public override bool Equals(object other) { 5375 return Equals(other as Issue11987Message); 5376 } 5377 5378 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5379 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] Equals(Issue11987Message other)5380 public bool Equals(Issue11987Message other) { 5381 if (ReferenceEquals(other, null)) { 5382 return false; 5383 } 5384 if (ReferenceEquals(other, this)) { 5385 return true; 5386 } 5387 if (A != other.A) return false; 5388 if (B != other.B) return false; 5389 if (C != other.C) return false; 5390 return Equals(_unknownFields, other._unknownFields); 5391 } 5392 5393 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5394 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] GetHashCode()5395 public override int GetHashCode() { 5396 int hash = 1; 5397 if (A != 0) hash ^= A.GetHashCode(); 5398 if (B != 0) hash ^= B.GetHashCode(); 5399 if (C != 0) hash ^= C.GetHashCode(); 5400 if (_unknownFields != null) { 5401 hash ^= _unknownFields.GetHashCode(); 5402 } 5403 return hash; 5404 } 5405 5406 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5407 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] ToString()5408 public override string ToString() { 5409 return pb::JsonFormatter.ToDiagnosticString(this); 5410 } 5411 5412 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5413 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] WriteTo(pb::CodedOutputStream output)5414 public void WriteTo(pb::CodedOutputStream output) { 5415 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5416 output.WriteRawMessage(this); 5417 #else 5418 if (A != 0) { 5419 output.WriteRawTag(8); 5420 output.WriteInt32(A); 5421 } 5422 if (B != 0) { 5423 output.WriteRawTag(16); 5424 output.WriteInt32(B); 5425 } 5426 if (C != 0) { 5427 output.WriteRawTag(24); 5428 output.WriteInt32(C); 5429 } 5430 if (_unknownFields != null) { 5431 _unknownFields.WriteTo(output); 5432 } 5433 #endif 5434 } 5435 5436 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5437 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5438 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalWriteTo(ref pb::WriteContext output)5439 void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { 5440 if (A != 0) { 5441 output.WriteRawTag(8); 5442 output.WriteInt32(A); 5443 } 5444 if (B != 0) { 5445 output.WriteRawTag(16); 5446 output.WriteInt32(B); 5447 } 5448 if (C != 0) { 5449 output.WriteRawTag(24); 5450 output.WriteInt32(C); 5451 } 5452 if (_unknownFields != null) { 5453 _unknownFields.WriteTo(ref output); 5454 } 5455 } 5456 #endif 5457 5458 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5459 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] CalculateSize()5460 public int CalculateSize() { 5461 int size = 0; 5462 if (A != 0) { 5463 size += 1 + pb::CodedOutputStream.ComputeInt32Size(A); 5464 } 5465 if (B != 0) { 5466 size += 1 + pb::CodedOutputStream.ComputeInt32Size(B); 5467 } 5468 if (C != 0) { 5469 size += 1 + pb::CodedOutputStream.ComputeInt32Size(C); 5470 } 5471 if (_unknownFields != null) { 5472 size += _unknownFields.CalculateSize(); 5473 } 5474 return size; 5475 } 5476 5477 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5478 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(Issue11987Message other)5479 public void MergeFrom(Issue11987Message other) { 5480 if (other == null) { 5481 return; 5482 } 5483 if (other.A != 0) { 5484 A = other.A; 5485 } 5486 if (other.B != 0) { 5487 B = other.B; 5488 } 5489 if (other.C != 0) { 5490 C = other.C; 5491 } 5492 _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); 5493 } 5494 5495 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5496 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] MergeFrom(pb::CodedInputStream input)5497 public void MergeFrom(pb::CodedInputStream input) { 5498 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5499 input.ReadRawMessage(this); 5500 #else 5501 uint tag; 5502 while ((tag = input.ReadTag()) != 0) { 5503 if ((tag & 7) == 4) { 5504 // Abort on any end group tag. 5505 return; 5506 } 5507 switch(tag) { 5508 default: 5509 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); 5510 break; 5511 case 8: { 5512 A = input.ReadInt32(); 5513 break; 5514 } 5515 case 16: { 5516 B = input.ReadInt32(); 5517 break; 5518 } 5519 case 24: { 5520 C = input.ReadInt32(); 5521 break; 5522 } 5523 } 5524 } 5525 #endif 5526 } 5527 5528 #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE 5529 [global::System.Diagnostics.DebuggerNonUserCodeAttribute] 5530 [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)5531 void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { 5532 uint tag; 5533 while ((tag = input.ReadTag()) != 0) { 5534 if ((tag & 7) == 4) { 5535 // Abort on any end group tag. 5536 return; 5537 } 5538 switch(tag) { 5539 default: 5540 _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); 5541 break; 5542 case 8: { 5543 A = input.ReadInt32(); 5544 break; 5545 } 5546 case 16: { 5547 B = input.ReadInt32(); 5548 break; 5549 } 5550 case 24: { 5551 C = input.ReadInt32(); 5552 break; 5553 } 5554 } 5555 } 5556 } 5557 #endif 5558 5559 } 5560 5561 #endregion 5562 5563 } 5564 5565 #endregion Designer generated code 5566